diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-10-01 21:52:40 +0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-10-01 21:52:40 +0400 |
commit | aaf675f53a7176475f69595827248c8b2556ea8c (patch) | |
tree | 0cb744dec714328c9f89bf85553fb7195107e5d4 /drivers/hwmon/ad7314.c | |
parent | 347c4e95845fad1853c0e3da6603a44c5d6122b3 (diff) | |
parent | a0d271cbfed1dd50278c6b06bead3d00ba0a88f9 (diff) | |
download | linux-aaf675f53a7176475f69595827248c8b2556ea8c.tar.xz |
Merge tag 'v3.6' into staging/for_v3.7
Linux 3.6
* tag 'v3.6': (562 commits)
Linux 3.6
vfs: dcache: fix deadlock in tree traversal
mtdchar: fix offset overflow detection
thp: avoid VM_BUG_ON page_count(page) false positives in __collapse_huge_page_copy
iommu/amd: Fix wrong assumption in iommu-group specific code
netdev: octeon: fix return value check in octeon_mgmt_init_phy()
ALSA: snd-usb: fix next_packet_size calls for pause case
inetpeer: fix token initialization
qlcnic: Fix scheduling while atomic bug
bnx2: Clean up remaining iounmap
trivial select_parent documentation fix
net: phy: smsc: Implement PHY config_init for LAN87xx
smsc75xx: fix resume after device reset
um: Preinclude include/linux/kern_levels.h
um: Fix IPC on um
netdev: pasemi: fix return value check in pasemi_mac_phy_init()
team: fix return value check
l2tp: fix return value check
USB: Fix race condition when removing host controllers
USB: ohci-at91: fix null pointer in ohci_hcd_at91_overcurrent_irq
...
Diffstat (limited to 'drivers/hwmon/ad7314.c')
-rw-r--r-- | drivers/hwmon/ad7314.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/hwmon/ad7314.c b/drivers/hwmon/ad7314.c index cfec802cf9ca..f915eb1c29f7 100644 --- a/drivers/hwmon/ad7314.c +++ b/drivers/hwmon/ad7314.c @@ -87,10 +87,18 @@ static ssize_t ad7314_show_temperature(struct device *dev, } } +static ssize_t ad7314_show_name(struct device *dev, + struct device_attribute *devattr, char *buf) +{ + return sprintf(buf, "%s\n", to_spi_device(dev)->modalias); +} + +static DEVICE_ATTR(name, S_IRUGO, ad7314_show_name, NULL); static SENSOR_DEVICE_ATTR(temp1_input, S_IRUGO, ad7314_show_temperature, NULL, 0); static struct attribute *ad7314_attributes[] = { + &dev_attr_name.attr, &sensor_dev_attr_temp1_input.dev_attr.attr, NULL, }; |