Re: PCMCIA issue on kernel 5.4.0-54-generic (Linux Mint 19.3)

Mitchell Clement <[email protected]> Mon, 30 Nov 2020 09:58:40 -0800
Newsgroups gmane.linux.hardware.gpib.general
Message-ID <CAH5DMbmz_ciHMk9TmoBXaEySFi=Nt21j1Dj2E+fi+O8wCuJkMg@mail.gmail.com>
Dave,

Worked like a charm, thanks.

Mitchell

On Mon, Nov 30, 2020 at 2:32 AM dave penkler <[email protected]> wrote:

> Hi Mitchell,
> Looks like a registration issue. The fix below seems to work.
>
> Please add the following line after line number 260 in tnt4882_cs.c and
> rebuild:  make clean; make ENABLE_PCMCIA=1; sudo make install; sudo
> modprobe tnt4882
> .*name = "ni_gpib_cs",*
>
> The first lines of the struct should look like this:
>
>
>
>
>
>
> *static struct pcmcia_driver ni_gpib_cs_driver ={ .name           =
> "ni_gpib_cs", .owner = THIS_MODULE,....*
>
> *};*
> Let me know if it works for you.
> cheers,
> -Dave
>
> On Mon, 30 Nov 2020 at 01:45, Mitchell Clement <[email protected]>
> wrote:
>
>> Hi,
>>
>> I am trying to build the linux-gpib kernel module with PCMCIA enabled for
>> Linux Mint 19.3 with kernel 5.4.0-54-generic, with a National Instruments
>> PCMCIA-GPIB card. When I try to modprobe the tnt4882 driver into the
>> kernel, I get:
>> $ sudo modprobe -fvv tnt4882
>> modprobe: INFO: ../libkmod/libkmod.c:364 kmod_set_log_fn() custom logging
>> function 0x55eae3517750 registered
>> insmod /lib/modules/5.4.0-54-generic/gpib/tnt4882/tnt4882.ko
>> modprobe: INFO: ../libkmod/libkmod-module.c:886
>> kmod_module_insert_module() Failed to insert module
>> '/lib/modules/5.4.0-54-generic/gpib/tnt4882/tnt4882.ko': Exec format error
>> modprobe: ERROR: could not insert 'tnt4882': Exec format error
>> modprobe: INFO: ../libkmod/libkmod.c:331 kmod_unref() context
>> 0x55eae482e420 released
>>
>> with dmesg output:
>> $ dmesg | tail
>> [ 7116.877246] gpib: registered ni_isa_accel interface
>> [ 7116.877247] gpib: registered ni_nat4882_isa interface
>> [ 7116.877248] gpib: registered ni_nat4882_isa_accel interface
>> [ 7116.877249] gpib: registered ni_nec_isa interface
>> [ 7116.877250] gpib: registered ni_nec_isa_accel interface
>> [ 7116.877250] gpib: registered ni_pci interface
>> [ 7116.877251] gpib: registered ni_pci_accel interface
>> [ 7116.877252] gpib: registered ni_pcmcia interface
>> [ 7116.877253] gpib: registered ni_pcmcia_accel interface
>> [ 7116.877256] kobject: can not set name properly!
>>
>> I don't think this is an issue of compiling against an incomplete symbol
>> table, as the gpib_common and nec7210 drivers are in my kernel:
>> $ lsmod | grep nec7210
>> nec7210                24576  0
>> gpib_common            45056  1 nec7210
>>
>> and so is the pcmcia driver:
>> $ lsmod | grep pcmcia
>> pcmcia                 65536  0
>> pcmcia_rsrc            24576  1 yenta_socket
>> pcmcia_core            28672  3 pcmcia,pcmcia_rsrc,yenta_socket
>>
>> I have no issues inserting tnt4882 into the kernel if I build it without
>> PCMCIA enabled (i.e. make ENABLE_PCMCIA=0). Does anyone have any idea what
>> is going on? Thanks.
>> _______________________________________________
>> Linux-gpib-general mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/linux-gpib-general
>>
>

_______________________________________________
Linux-gpib-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-gpib-general