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-next>] [day] [month] [year] [list]
Message-ID: <409519530.22419.1309373631423.JavaMail.root@sz0140a.emeryville.ca.mail.comcast.net>
Date:	Wed, 29 Jun 2011 18:53:51 +0000 (UTC)
From:	johnlinn@...cast.net
To:	linux-kernel@...r.kernel.org
Subject: using a single sysfs show function for multiple device attributes

In a platform driver, I'm trying to use a single function for multiple device attributes and use the attr input to ID which attribute.

After the driver is up and running, the sysfs attributes exist.  In my show function getting a device_attribute as an input, I never see the device attribute (attr) having anything in it (all 0s).  I see the attr pointer be valid, but pointing to all 0's.  

I don't see others using the attr input, but it seems like the way to ID which attribute is being accessed so that one show function can be used for many attributes.

I'm sure it's obvious, but I don't see what I'm doing wrong.

Thanks,
John
--
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