Description of problem: PCSCD is taking 80%-99% of CPU without any reason or messages. The only message I got in /var/log/messages is: pcscd: prothandler.c:109:PHSetProtocol() Protocol T=0 requested but unsupported by the card Smart Card reader is GEMPC card PCMCIA using ccid driver. File reader.conf is -------------------------------------------------------------------------- # /etc/reader.conf.d/gempc.conf # Gemplus reader with serial communication # - n is the serial port to use n in [0..3] # - reader is the reader name. It is needed for multi-slot readers. # Possible reader values are: GemPCPinPad, GemCorePOSPro, GemCoreSIMPro, # GemPCTwin (default value) # example: /dev/ttyS0:GemPCPinPad FRIENDLYNAME "GemPCTwin serial" DEVICENAME /dev/ttyS2 LIBPATH /usr/lib/pcsc/drivers/serial/libccidtwin.so.1.2.1 CHANNELID 2 -------------------------------------------------------------------------- The smartcard is an OpenPGP. pcsc-lite is 1.3.3-1.fc7 ccid is 1.2.1-1fc7 smartcard is working fine. System is working fine. vmstat as follows: procs -----------memory---------- ---swap-- -----io---- --system-- -----cpu------ r b swpd free buff cache si so bi bo in cs us sy id wa st 3 0 176 10892 42636 337032 0 0 114 94 866 915 42 11 44 2 0 2 0 176 8796 42656 339172 0 0 0 2236 1307 394 65 35 0 0 0 4 0 176 28240 42668 319580 0 0 0 0 1284 376 65 36 0 0 0 3 0 176 26376 42668 321552 0 0 6 0 1277 388 63 37 0 0 0 6 0 176 25776 42680 322132 0 0 12 2918 1322 371 62 38 0 0 0 3 1 176 25388 42680 322604 0 0 18 0 1259 366 61 39 0 0 0
Do you have any other reader drivers installed, and if so what versions?
No, CCID is the only activated reader in readers.conf There's openct installed as rpm, but is commented out. Note that if I remove the pcmcia reader to use the UMTS card, pcsc will stay 80-95% of cpu. Of course I stop it when using UTMS, because it's useless.
The real question is what is the output of the command: $ file /usr/lib/pcsc/drivers/
This is the output: ~$ find /usr/lib/pcsc/drivers/ /usr/lib/pcsc/drivers/ /usr/lib/pcsc/drivers/openct-ifd.bundle /usr/lib/pcsc/drivers/openct-ifd.bundle/Contents /usr/lib/pcsc/drivers/openct-ifd.bundle/Contents/Info.plist /usr/lib/pcsc/drivers/openct-ifd.bundle/Contents/PkgInfo /usr/lib/pcsc/drivers/openct-ifd.bundle/Contents/Linux /usr/lib/pcsc/drivers/openct-ifd.bundle/Contents/Linux/openct-ifd.so /usr/lib/pcsc/drivers/serial /usr/lib/pcsc/drivers/serial/libccidtwin.so.1.2.1 /usr/lib/pcsc/drivers/ifd-egate.bundle /usr/lib/pcsc/drivers/ifd-egate.bundle/Contents /usr/lib/pcsc/drivers/ifd-egate.bundle/Contents/Info.plist /usr/lib/pcsc/drivers/ifd-egate.bundle/Contents/Linux /usr/lib/pcsc/drivers/ifd-egate.bundle/Contents/Linux/libifd_egate.so /usr/lib/pcsc/drivers/ifd-ccid.bundle /usr/lib/pcsc/drivers/ifd-ccid.bundle/Contents /usr/lib/pcsc/drivers/ifd-ccid.bundle/Contents/Info.plist /usr/lib/pcsc/drivers/ifd-ccid.bundle/Contents/Linux /usr/lib/pcsc/drivers/ifd-ccid.bundle/Contents/Linux/libccid.so.1.2.1 The real problem is that pcscd keep scanning the usb bus in an infinitive loop. An interim (workaround) solution would be a "sleep" between the scan of the usb bus. Maybe the long term solution would be based on udev (but i'm not a developer).
Created attachment 222331 [details] strace of pcscd showing the usb scan This is the strace of pcscd showing that the usb scanning is in infinitive loop. this take me 100% of cpu, and in my laptop fans are ON all the times and my (poor) battery is lasting no more than 30mins.
You are using 3 drivers for USB readers: - openct-ifd - ifd-egate - ifd-ccid I suggest to move all three *.bundle directories to somewhere else and then move them back one at a time and restart pcscd after each addition of a driver to see if CPU load is high. It looks like a known bug in the ifd-egate and/or openct-ifd driver. See also bugs 229263 and 232983
Hi Ludovic, you're great. Removing openct worked fine and now the CPU has reasonable level. Maybe we can mark this bug as dups of the above bug #229263 *** This bug has been marked as a duplicate of 229263 ***
(In reply to comment #7) > Hi Ludovic, you're great. Yes, I know. I have no objection if Red Hat wants to hire me :-) Just use my private e-mail.