Re: PCMCIA GPIB help with linux-gpib-4.3.0

Mitchell Clement <[email protected]> Wed, 8 Apr 2020 20:24:09 -0700
Newsgroups gmane.linux.hardware.gpib.general
Message-ID <CAH5DMbm8cLiF+CBVbyewo3bh9aHW+MtCF7hW-HQqJae1ji+tFg@mail.gmail.com>
Thanks for the updates, this works for me now.

On Wed, Apr 8, 2020 at 8:01 AM dave penkler <[email protected]> wrote:

> There was an issue with the previous tip since the option was not being
> passed down to the individual module compilation steps.
> The SVN has been updated accordingly. Please check the INSTALL files in
> both the user and kernel directories regarding PCMCIA support and let
> know if you have any issues.
> You can see the changes here
> <https://sourceforge.net/p/linux-gpib/code/1873/>.
> Thanks,
> -Dave
>
> On Wed, 8 Apr 2020 at 10:28, Roel Jordans <[email protected]> wrote:
>
>> Hi Mitchell,
>>
>> Then probably a make clean before your new make should have helped.
>> Since there were no changes to the files themselves (except for the
>> Makefile) make typically will assume that the old build result is still
>> valid.
>>
>> Cheers,
>>  Roel
>>
>> -----Original Message-----
>> From: Mitchell Clement <[email protected]>
>> To: dave penkler <[email protected]>
>> Cc: [email protected]
>> Subject: Re: [Linux-gpib-general] PCMCIA GPIB help with linux-gpib-
>> 4.3.0
>> Date: Tue, 7 Apr 2020 13:18:16 -0700
>>
>> Dave,
>>
>> Thanks for the tip. I changed the Makefile per your instructions, but
>> that didn't seem to work. As a workaround, I went into the drive
>> directory and commented out all of the #ifdef(GPIB_CONFIG_PCMCIA) lines
>> and built the kernel and that worksI think. After doing $ sudo
>> gpib_config --minor 0, the output of $ dmesg | grep gpib, shows:
>> [   16.730076] gpib_common: loading out-of-tree module taints kernel.
>> [   16.733090] gpib_common: module verification failed: signature
>> and/or required key missing - tainting kernel
>> [   16.764816] gpib: registered ni_isa interface
>> [   16.767173] gpib: registered ni_isa_accel interface
>> [   16.768955] gpib: registered ni_nat4882_isa interface
>> [   16.770737] gpib: registered ni_nat4882_isa_accel interface
>> [   16.772486] gpib: registered ni_nec_isa interface
>> [   16.774209] gpib: registered ni_nec_isa_accel interface
>> [   16.775886] gpib: registered ni_pci interface
>> [   16.777530] gpib: registered ni_pci_accel interface
>> [   16.779148] gpib: registered ni_pcmcia interface
>> [   16.780691] gpib: registered ni_pcmcia_accel interface
>> [   16.783782] ni_gpib_probe(0xffff8b7ef6a83800)
>> [   16.783785] ni_gpib_config(0xffff8b7ef6a83800)
>> [  151.273150] gpib debug: pid 9313, gpib: opening minor 0
>> [  151.278597] gpib debug: pid 9313, gpib: request module returned 256
>> [  151.278619] gpib debug: pid 9313, minor 0, ioctl 39, interface=,
>> use=0, onl=0
>> [  151.278628] gpib debug: pid 9313, minor 0, ioctl 24, interface=,
>> use=0, onl=0
>> [  151.278634] gpib debug: pid 9313, minor 0, ioctl 21,
>> interface=ni_pcmcia, use=1, onl=0
>> [  151.278638] gpib debug: pid 9313, minor 0, ioctl 22,
>> interface=ni_pcmcia, use=1, onl=0
>> [  151.278643] gpib debug: pid 9313, minor 0, ioctl 23,
>> interface=ni_pcmcia, use=1, onl=0
>> [  151.278647] gpib debug: pid 9313, minor 0, ioctl 15,
>> interface=ni_pcmcia, use=1, onl=0
>> [  151.278650] gpib debug: set primary addr to 0
>> [  151.278654] gpib debug: pid 9313, minor 0, ioctl 16,
>> interface=ni_pcmcia, use=1, onl=0
>> [  151.278656] gpib debug: set secondary addr to -96
>> [  151.278660] gpib debug: pid 9313, minor 0, ioctl 32,
>> interface=ni_pcmcia, use=1, onl=0
>> [  151.278666] gpib debug: pid 9313, minor 0, ioctl 43,
>> interface=ni_pcmcia, use=1, onl=0
>> [  151.278682] gpib debug: pid 9313, minor 0, ioctl 44,
>> interface=ni_pcmcia, use=1, onl=0
>> [  151.278739] gpib debug: pid 9313, minor 0, ioctl 39,
>> interface=ni_pcmcia, use=1, onl=0
>> [  151.279068] gpib debug: gpib: board online
>> [  151.279505] gpib debug: pid 9313, gpib: opening minor 0
>> [  151.279514] gpib debug: pid 9313, minor 0, ioctl 26,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279517] gpib debug: pid 9313, locked board 0 mutex
>> [  151.279522] gpib debug: pid 9313, minor 0, ioctl 34,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279537] gpib debug: pid 9313, minor 0, ioctl 5,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279554] gpib debug: pid 9313, minor 0, ioctl 26,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279557] gpib debug: pid 9313, unlocked board 0 mutex
>> [  151.279565] gpib debug: pid 9313, minor 0, ioctl 26,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279567] gpib debug: pid 9313, locked board 0 mutex
>> [  151.279572] gpib debug: pid 9313, minor 0, ioctl 29,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279576] gpib debug: pid 9313, minor 0, ioctl 9,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279579] gpib debug: sending interface clear
>> [  151.279623] gpib debug: minor 0, isr1 0x0, imr1 0xbf, isr2 0x89,
>> imr2 0x4f
>> [  151.279693] gpib debug: pid 9313, minor 0, ioctl 5,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279707] gpib debug: pid 9313, minor 0, ioctl 26,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279710] gpib debug: pid 9313, unlocked board 0 mutex
>> [  151.279716] gpib debug: pid 9313, minor 0, ioctl 26,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279719] gpib debug: pid 9313, locked board 0 mutex
>> [  151.279723] gpib debug: pid 9313, minor 0, ioctl 29,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279727] gpib debug: pid 9313, minor 0, ioctl 10,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279737] gpib debug: pid 9313, minor 0, ioctl 5,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279751] gpib debug: pid 9313, minor 0, ioctl 26,
>> interface=ni_pcmcia, use=2, onl=1
>> [  151.279753] gpib debug: pid 9313, unlocked board 0 mutex
>> [  151.279759] gpib debug: pid 9313, gpib: closing minor 0
>> [  151.279948] gpib debug: pid 9313, gpib: closing minor 0
>> [  151.285747] gpib debug: entering autospoll thread
>>
>> Thanks.
>>
>> Mitchell
>>
>> On Tue, Apr 7, 2020 at 8:27 AM dave penkler <[email protected]> wrote:
>> > Hi Mitchell,
>> > The kernel module for ni_pcmcia and ni_pcmcia_accel is the tnt4882.ko
>> > module which seems to exist from your dmesg.
>> > We forgot to put a GPIB_CONFIG_PCMCIA config option into the Makefile
>> > when autoconf was dropped for the kernel modules build.
>> > Please edit the "all" target in the top level Makefile in the linux-
>> > gpib-kernel-4.3.0 directory to look like so:
>> > all:
>> >     -$(MAKE) -C $(LINUX_SRCDIR) V=$(VERBOSE) modules \
>> >         M="$(GPIB_SRCDIR)/drivers/gpib" \
>> >         GPIB_TOP_DIR=$(GPIB_SRCDIR) \
>> >         CONFIG_GPIB_ISA="$(ENABLE_ISA)" \
>> >         HAVE_DEV_OF_NODE=$(HAVE_DEV_OF_NODE) \
>> >         GPIB_CONFIG_KERNEL_DEBUG=$(GPIB_DEBUG) \
>> >         GPIB_CONFIG_PCMCIA=1
>> >
>> > Rebuild and install the kernel modules with the above modification
>> > and reboot to test.
>> > BTW: The gpib_config command should be: gpib_config --minor 0.
>> > Cheers,
>> > -Dave
>> >
>> > On Tue, 7 Apr 2020 at 02:02, Mitchell Clement <[email protected]>
>> > wrote:
>> > > Hi, I'm new to the Linux-GPIB community and am hoping to get some
>> > > guidance on getting my National Instruments PCMCIA-GPIB card
>> > > working with linux-gpib-4.3.0.
>> > >
>> > > TL;DR: Are there better instructions for getting PCMCIA cards to
>> > > work with linux-gpib than is what is contained in "linux-gpib-user-
>> > > 4.3.0/INSTALL"?
>> > >
>> > > Full details:
>> > > I am running CentOS 7.7.1908, with a custom kernel (3.10.0-
>> > > 1062.18.1.rt56.1044.el7.x86_64). I have successfully built the
>> > > kernel driver and installed the user space package. The
>> > > instructions contained in the linux-gpib-user-4.3.0/INSTALL file
>> > > appear to be very outdated for PCMCIA, as it makes reference to the
>> > > cardmgr daemon (as far as I know cardmgr was replaced by pccardctl
>> > > and lspcmcia). I edited the "board_type" field in "/etc/gpib.conf"
>> > > to "ni_pcmcia". As instructed, I copied the etc/pcmcia subdirectory
>> > > to /etc/pcmcia. I am assuming the script "/etc/pcmcia/linux-gpib-
>> > > pcmcia" is supposed to be run somehow, when a pcmcia card is
>> > > inserted, but I am unable to get it to run from the terminal. I am
>> > > able to insert the kernel module drivers: gpib_common, nec7210,
>> > > tnt4882, but when try issuing the command:
>> > > $ sudo gpib_config 0
>> > > , I get:
>> > > failed to configure boardtype: ni_pcmcia
>> > > failed to configure board
>> > > main: Invalid argument
>> > > I checked the output of dmesg after inserting the drivers and see
>> > > that the following interfaces get registered:
>> > > [ 1495.671213] gpib: registered ni_isa interface
>> > > [ 1495.671220] gpib: registered ni_isa_accel interface
>> > > [ 1495.671223] gpib: registered ni_nat4882_isa interface
>> > > [ 1495.671225] gpib: registered ni_nat4882_isa_accel interface
>> > > [ 1495.671227] gpib: registered ni_nec_isa interface
>> > > [ 1495.671229] gpib: registered ni_nec_isa_accel interface
>> > > [ 1495.671231] gpib: registered ni_pci interface
>> > > [ 1495.671233] gpib: registered ni_pci_accel interface
>> > > ni_pcmcia is nowhere to be found. Looking in the tnt4882 driver
>> > > source, I see that all the above listed interfaces have definitions
>> > > in "tnt4882_init.c" which I assume contains all the initialization
>> > > routines when the drive module is inserted in the kernel. The
>> > > pcmcia init routines are found in "tnt4882_cs.c". It seems that
>> > > PCMCIA is a dying bus interface and am wondering if maybe the
>> > > ni_pcmcia routines should have been added to "tnt4882_init.c" some
>> > > time ago or am I doing something wrong? Thanks for the help and
>> > > reading my lengthy email.
>> > >
>> > > Mitchell
>> > > _______________________________________________
>> > > 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
>>
>>

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