[OpenAFS-devel] sys_call_table on mips

Ryan Underwood nemesis-lists@icequake.net
Tue, 16 Sep 2003 23:19:27 -0500


Hi,

On Tue, Sep 16, 2003 at 12:55:46AM -0400, Derrick J Brashear wrote:
> On Mon, 15 Sep 2003, Ryan Underwood wrote:
> 
> > > No, the Debian kernels for mips are built without modversions.  This
> > > presented problems for ALSA as well; I assume there is a good reason for
> > > it.
> >
> > Sooo.. without modversions and without sys_call_table, what is necessary
> > to set up the kernel hooks?
> 
> You should really fix the kernel to use modversions, but...

Yeah, another day perhaps...

> either find the address of sys_call_table, initialize sys_call_table to
> that value in the right place in src/afs/LINUX/osi_module.c
> or edit afsconfig.h such that it knows sys_call_table isn't exported,
> *and* knows which sys_(mumble)s are exported, so it can look for it with
> those.

Hm, I see no sys_(mumble)s exported like on other archs.  Here is the
list of symbols exported by the general mips code.

kernel/smp.c:EXPORT_SYMBOL(smp_num_cpus);
kernel/smp.c:EXPORT_SYMBOL(flush_tlb_page);
kernel/smp.c:EXPORT_SYMBOL(cpu_data);
kernel/smp.c:EXPORT_SYMBOL(synchronize_irq);
kernel/smp.c:EXPORT_SYMBOL(kernel_flag);
kernel/smp.c:EXPORT_SYMBOL(__global_sti);
kernel/smp.c:EXPORT_SYMBOL(__global_cli);
kernel/smp.c:EXPORT_SYMBOL(__global_save_flags);
kernel/smp.c:EXPORT_SYMBOL(__global_restore_flags);
kernel/setup.c:EXPORT_SYMBOL(mips_io_port_base);
kernel/setup.c:EXPORT_SYMBOL(isa_slot_offset);
kernel/pci-dma.c:EXPORT_SYMBOL(pci_alloc_consistent);
kernel/pci-dma.c:EXPORT_SYMBOL(pci_free_consistent);
kernel/old-irq.c:EXPORT_SYMBOL(free_irq);
kernel/old-irq.c:EXPORT_SYMBOL(request_irq);
kernel/mips_ksyms.c:EXPORT_SYMBOL(mips_machtype);
kernel/mips_ksyms.c:EXPORT_SYMBOL(EISA_bus);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(memcmp);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(memset);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(memcpy);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(memmove);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(strcat);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(strchr);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(strlen);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(strpbrk);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(strncat);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(strnlen);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(strrchr);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(strstr);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(strtok);
kernel/mips_ksyms.c:EXPORT_SYMBOL(_clear_page);
kernel/mips_ksyms.c:EXPORT_SYMBOL(kernel_thread);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(__copy_user);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(__bzero);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(__strncpy_from_user_nocheck_asm);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(__strncpy_from_user_asm);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(__strlen_user_nocheck_asm);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(__strlen_user_asm);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(__strnlen_user_nocheck_asm);
kernel/mips_ksyms.c:EXPORT_SYMBOL_NOVERS(__strnlen_user_asm);
kernel/mips_ksyms.c:EXPORT_SYMBOL(csum_partial_copy);
kernel/mips_ksyms.c:EXPORT_SYMBOL(_flush_page_to_ram);
kernel/mips_ksyms.c:EXPORT_SYMBOL(_flush_cache_all);
kernel/mips_ksyms.c:EXPORT_SYMBOL(invalid_pte_table);
kernel/mips_ksyms.c:EXPORT_SYMBOL(__down);
kernel/mips_ksyms.c:EXPORT_SYMBOL(__down_interruptible);
kernel/mips_ksyms.c:EXPORT_SYMBOL(__down_trylock);
kernel/mips_ksyms.c:EXPORT_SYMBOL(__up);
kernel/mips_ksyms.c:EXPORT_SYMBOL(vdma_alloc);
kernel/mips_ksyms.c:EXPORT_SYMBOL(vdma_free);
kernel/mips_ksyms.c:EXPORT_SYMBOL(vdma_log2phys);
kernel/mips_ksyms.c:EXPORT_SYMBOL(hpc3c0);
kernel/mips_ksyms.c:EXPORT_SYMBOL(hpc3c1);
kernel/mips_ksyms.c:EXPORT_SYMBOL(mcmisc_regs);
kernel/mips_ksyms.c:EXPORT_SYMBOL(screen_info);
kernel/mips_ksyms.c:EXPORT_SYMBOL(ide_ops);
kernel/mips_ksyms.c:EXPORT_SYMBOL(get_wchan);
kernel/irq.c:EXPORT_SYMBOL(disable_irq_nosync);
kernel/irq.c:EXPORT_SYMBOL(disable_irq);
kernel/irq.c:EXPORT_SYMBOL(enable_irq);
kernel/irq.c:EXPORT_SYMBOL(probe_irq_mask);

> Or, make the address a module parameter to be passed in.

Perhaps given the circumstances, and the fact that new mips kernels are
rarely released, this might end up being the best option?

-- 
Ryan Underwood, <nemesis at icequake.net>, icq=10317253