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]
Message-ID: <BF5CB373A5A948A2976AE727EA3F6B70@hacdom.okisemi.com>
Date:	Wed, 2 Mar 2011 15:38:13 +0900
From:	"Tomoya MORINAGA" <tomoya-linux@....okisemi.com>
To:	"'Grant Likely'" <grant.likely@...retlab.ca>
Cc:	<linux-kernel@...r.kernel.org>,
	"'Ewe, Kok Howg'" <kok.howg.ewe@...el.com>,
	"'Lai, Mee Sim'" <mee.sim.lai@...el.com>,
	"'Toshiharu Okada'" <toshiharu-linux@....okisemi.com>
Subject: RE: About GPIO interrupt function with sysfs

Hi Grant,

On Friday, February 18, 2011 9:43 AM, Grant Likely wrote:
> > Can our GPIO driver (pch_gpio) have interrupt function?
> 
> yes.
Need your help.

I try to add interrupt function to GPIO driver of Intel EG20T PCH(pch_gpio.c).

However, executing "echo xxx > export", there is not "edge" file in /sys/class/gpio/gpioxxx/.

Seeing source code in gpio_export@...olib.c, like below

int gpio_export(unsigned gpio, bool direction_may_change)
{
snip...

	if (!status && gpio_to_irq(gpio) >= 0
			&& (direction_may_change
				|| !test_bit(FLAG_IS_OUT,
					&desc->flags))) {
		status = device_create_file(dev,
				&dev_attr_edge);
		printk("%s:device_create_file!!! status=0x%x\n", __func__, status);
	}

snip...
}

The above "device_create_file(dev, &dev_attr_edge);" is not executed.

Seeing gpio_to_irq@...h/x86/include/asm/gpio.h, like below.

static inline int gpio_to_irq(unsigned int gpio)
{
	return -ENOSYS;
}

Thus,  device_create_file for "edge" is never executed.

Could you tell me how to create "edge" file ?

With Best Regards,
-----------------------------------------
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