lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 22 Apr 2011 10:12:29 +0900
From:	"Tomoya MORINAGA" <tomoya-linux@....okisemi.com>
To:	"'Grant Likely'" <grant.likely@...retlab.ca>,
	"'Lars-Peter Clausen'" <lars@...afoo.de>
Cc:	<linux-kernel@...r.kernel.org>, <toshiharu-linux@....okisemi.com>
Subject: RE: Question: GPIO driver how to get irq_base

Hi Grant, Lars-Peter Clausen,

- Executing the following command,
  cd /sys/class/gpio/gpio244
  echo "falling" > edge

- I can see the following error message.
  IRQ handler type mismatch for IRQ 18
  current handler: spi_topcliff_pch
  Pid: 3269, comm: bash Not tainted 2.6.38.3.upstream_check+ #23
  Call Trace:
   [<c0470682>] ? __setup_irq+0x257/0x2a9
   [<c054a45f>] ? gpio_sysfs_irq+0x0/0x11
   [<c047077c>] ? request_threaded_irq+0xa8/0xce
   [<c04707fb>] ? request_any_context_irq+0x59/0x64
   [<c054a45f>] ? gpio_sysfs_irq+0x0/0x11
   [<c054a8f5>] ? gpio_setup_irq.clone.4+0x1fa/0x292
   [<c054ae2c>] ? gpio_edge_store+0xa3/0xd2
   [<c054ad89>] ? gpio_edge_store+0x0/0xd2
   [<c05bf270>] ? dev_attr_store+0x1b/0x23
   [<c04e90a5>] ? sysfs_write_file+0xae/0xe7
   [<c04e8ff7>] ? sysfs_write_file+0x0/0xe7
   [<c04a71a1>] ? vfs_write+0x82/0xd9
   [<c04a7366>] ? sys_write+0x3b/0x5d
   [<c0403018>] ? sysenter_do_call+0x12/0x28

> Using the above, I can see "irq_base = 18d".
- According to the following "/proc/interrupts" information,
  I suspect pch_gpio can't use IRQ18.

[morinaga@...alhost ~]$ cat /proc/interrupts 
           CPU0       CPU1       
  0:      30881          0   IO-APIC-edge      timer
  1:          2          0   IO-APIC-edge      i8042
  4:          2          0   IO-APIC-edge    
  8:        128          0   IO-APIC-edge      rtc0
  9:          0          0   IO-APIC-fasteoi   acpi
 12:          4          0   IO-APIC-edge      i8042
 16:        385          0   IO-APIC-fasteoi   intel-eg20t-pch, ehci_hcd:usb2, ohci_hcd:usb6, ohci_hcd:usb7, ohci_hcd:usb8,
hda_intel
 17:          0          0   IO-APIC-fasteoi   eth1
 18:          0          0   IO-APIC-fasteoi   spi_topcliff_pch, i2c_eg20t, pch-dma, mmc0, mmc1
 19:       3599          0   IO-APIC-fasteoi   ehci_hcd:usb1, ohci_hcd:usb3, ohci_hcd:usb4, ohci_hcd:usb5, pch-dma,
mga@pci:0000:07:00.0
 40:      10298          0   PCI-MSI-edge      ahci
 42:         98          0   PCI-MSI-edge      eth0
NMI:          0          0   Non-maskable interrupts
LOC:      76268      72502   Local timer interrupts
SPU:          0          0   Spurious interrupts
PMI:          0          0   Performance monitoring interrupts
IWI:          0          0   IRQ work interrupts
RES:       1383       1842   Rescheduling interrupts
CAL:         67        108   Function call interrupts
TLB:        224        292   TLB shootdowns
TRM:          0          0   Thermal event interrupts
THR:          0          0   Threshold APIC interrupts
MCE:          0          0   Machine check exceptions
MCP:          1          1   Machine check polls
ERR:          0
MIS:          0

Let me know your opinion.

Thanks,
-----------------------------------------
Tomoya MORINAGA
OKI SEMICONDUCTOR CO., LTD.

 

> -----Original Message-----
> From: Tomoya MORINAGA [mailto:tomoya-linux@....okisemi.com] 
> Sent: Friday, April 22, 2011 9:33 AM
> To: 'Grant Likely'; 'Lars-Peter Clausen'
> Cc: 'linux-kernel@...r.kernel.org'; 'toshiharu-linux@....okisemi.com'
> Subject: RE: Question: GPIO driver how to get irq_base
> 
> Hi Grant, Lars-Peter Clausen
> 
> Thank you for your information.
> 
> It seems nothing driver uses irq_alloc_descs.
> Thus, let me clarify my using.
> 
> int irq_base = irq_alloc_descs(-1, 0, 12, GFP_KERNEL) 
> (Intel-ET20T-PCH has GPIO~GPIO11)
> 
> Using the above, I can see "irq_base = 18d".
> Is the above TRUE ?
> 
> Thanks,
> -----------------------------------------
> Tomoya MORINAGA
> OKI SEMICONDUCTOR CO., LTD.
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ