Delay the call to adapter->client_register() until after we are
certain that the client registration is a success. At this point the
client is fully initialized and we no longer hold the adapter->clist
mutex, so this should prevent the deadlocks if the client_register()
callback needs to take that mutex too, as is the case for the bttv
driver.
This fixes bug #7234.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
hwmon: Remove Yuan Mu's address
Yuan Mu no longer works at Winbond.
I wish to publicly thank Yuan for his help with Winbond hardware
monitoring chips support during the past 10 months.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
hwmon: Fix unchecked return status, SMSC chips
Fix up 2 more hwmon drivers so that they no longer ignore return
status from device_create_file().
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
hwmon: Fix unchecked return status, batch 6
Fix up 5 more hwmon drivers so that they no longer ignore return status
from device_create_file().
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
hwmon: Fix unchecked return status, batch 5
Fix up some hwmon drivers so that they no longer ignore return status
from device_create_file().
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
hwmon: Fix unchecked return status, batch 4
Fix up some hwmon drivers so that they no longer ignore return status
from device_create_file().
Note: f71805f actually checked the status from device_create_file
already. However it did not remove the files on device destruction.
It was also an opportunity to use sysfs_create/remove_group instead
of hand-made loops. This makes the changes much more important but
I think the result is worth it.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
hwmon: Add individual alarm files to 4 drivers
Add individual sysfs files for all f71805f, lm63, lm83 and lm90 alarm
and fault conditions. This is a requirement for the planned
chip-independent libsensors. Almost all other hwmon drivers will need
the same improvement.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
hwmon: Make a dozen drivers no more experimental
Remove the EXPERIMENTAL tag from a dozen hardware monitoring drivers.
They are in the tree for quite a long time, so we would know by now if
they were causing trouble.
Also make it clearer that the VT8231 is a VIA chip.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
it87: Copyright update
I think my contributions to the it87 driver over the past two
years qualify me as a co-author of this driver.
Also drop old comments of dubious usefulness.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
it87: Overwrite broken default limits
Some IT8716F chips where seen with unreasonable defaults for low
voltage and high temperature limits. Overwrite them with sane defaults
so as to not generate meaningless alarms.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
it87: Add support for the IT8718F
The IT8718F is a Super-I/O chip with integrated hardware monitoring
functions. It is very similar to the IT8716F, so adding support to the
it87 driver was pretty straightforward. The most significant difference
is that the IT8718F has up to 8 VID pins, instead of 6 for the older
chips.
For the IT8718F, the VID value can only be read from Super-I/O space.
Userspace support is already in lm_sensors SVN (to be soon released
as 2.10.1.)
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
it87: Cleanup set_fan_div
We only change one fan clock divider at a time, so there is only one
fan min which needs to be saved and restored.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
it87: Prevent overflow on fan clock divider write
The highest possible clock divider for fan1 and fan2 is 128.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
it87: No sysfs files for disabled fans
Only create the fan attributes for enabled fan tachometers. Some
motherboards have a nice BIOS which only enables the fan inputs which
are wired to a fan header on the board. This makes the configuration
easier for the user.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
it87: Add support for the IT8716F
The IT8716F is a Super-I/O chip with integrated hardware monitoring
functions. It is very similar to the IT8712F, so adding support to the
it87 driver was pretty straightforward. The most significant change here
is that the IT8716F has 16-bit fan speed counters, so the user no more
needs to tweak the fan clock dividers to get the best readings.
Userspace support is already in lm_sensors SVN (to be soon released
as 2.10.1.)
Thanks to Stian Oksavik, Olivier Nicolas, Prakash Punnoor and
Juergen Kilb for testing the early versions of this patch.
Thanks also to ITE for providing datasheets and answering my questions.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
smsc47m1: dev_warn fix
We can't use dev_warn on an i2c client before it is attached.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c: Drop unimplemented slave functions
Drop the function declarations for slave mode support of i2c adapters.
This was never implemented, and by the time it is I bet we will want
something different anyway.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c: Constify i2c_algorithm declarations, part 2
Make struct i2c_algorithm declarations const in all i2c bus drivers
where it is possible.
Signed-off-by: Jean Delvare <[email protected]>
Cc: David Brownell <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-isa: Restore driver owner
Commit 2b48716d1d back in January
2006 was a bit overzealous. It removed .owner from all i2c drivers,
including i2c-isa ones, while they still need it.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c: Warn on i2c client creation failure
Warn when an i2c client creation fails. If we don't, the user will
never know something wrong happened, as i2c client creation is
typically called through an attach_adapter callback, those return value
we currently ignore for technical reasons.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-core: Drop useless bitmaskings
The code generated is exactly the same.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-algo-bit: Cleanups
* Uninline long functions (saves around 1 kB or 15%)
* Refactor code in sclhi()
* Drop redundant udelay on repeated start
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c: __must_check fixes (chip drivers)
Check for error on sysfs file creation.
Delete sysfs files on device removal.
The approach taken for the most complex case (pcf8591) is similar to
what Mark M. Hoffman proposed for hardware monitoring chip drivers.
Signed-off-by: Jean Delvare <[email protected]>
Cc: Ben Gardner <[email protected]>
Cc: Aurelien Jarno <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-dev: attach/detach_adapter cleanups
* Only print that an adapter was attached when it succeeds.
* i2c_dev == NULL on detach simply means that the attach failed
before, this isn't an error per se.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-stub: Chip address as a module parameter
Add a mandatory chip_addr parameter to i2c-stub. This parameter
defines to which chip address the driver will respond, instead of
reponding to all addresses as before. The idea is to prevent the
users from loading i2c-stub at random and being then confused by
the results of sensors-detect or other user-space tools.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Mark M. Hoffman <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c: Plan i2c-isa for removal
i2c-isa doesn't make much sense in the device driver model. Drivers
relying on it are better implemented as platform drivers. We must
wait for recent versions of libsensors (2.10.0 or later) to be widely
deployed beforehand, though. This move should also make it easier to
convert i2c-core to the device driver model.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-algo-bit: Discard the mdelay data struct member
The i2c_algo_bit_data structure has an mdelay member, which is not
used by the algorithm code (the code has always been ifdef'd out.)
Let's discard it to save some code and memory.
Signed-off-by: Jean Delvare <[email protected]>
Acked-by: Mauro Carvalho Chehab <[email protected]>
Cc: Adrian Bunk <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-sibyte: Kip Walker is gone
Kip Walker no longer works at Broadcom, and his e-mail address there
bounces back, so let's drop it.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-algo-sibyte: Merge into i2c-sibyte
Merge i2c-algo-sibyte into i2c-sibyte, as this is a complete,
hardware-dependent SMBus implementation and not a reusable algorithm.
Perform some basic coding style cleanups while we're here (mainly
space-based indentation replaced by tabulations.)
Signed-off-by: Jean Delvare <[email protected]>
Cc: Ralf Baechle <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c: __must_check fixes (i2c-dev)
Check for error on sysfs file creation.
Check for error on device creation.
Delete sysfs file on device destruction.
I couldn't test this one beyond compilation, as it applies on top of
another patch in Greg's tree [1] which breaks all my systems when I
apply it (my udev isn't recent enough.) Anyone with bleeding edge udev
is welcome to test and report.
[1] http://www.kernel.org/pub/linux/kernel/people/gregkh/gregkh-2.6/patches/i2c/i2c-dev-device.patch
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c: __must_check fixes (core drivers)
Check for error on sysfs file creation.
Check for error on device registration.
Check for error on class device registration.
Greg, I am not familiar with completion, can you please tell me if I
need to take care of it in the error paths (as I did in this patch,
see /* Needed? */ comments), or if it isn't needed?
These patches were tested, including forced errors, so they should work
fine. But of course more testing can't hurt.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-dev: Drop the client template
Drop the i2c-dev client template. This saves about 360 bytes of
memory. I got the idea from a similar cleanup Hans-Frieder Vogt
made to i2c-nforce2 recently.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-dev: Use a list for data storage
Use a list instead of a static array for storing the i2c-dev data.
Given that most systems have less than 10 i2c busses, most of the
space was wasted, so this saves around 1 kB of memory (2 kB on 64-bit
archs.)
The drawback is that lookup was in O(1) and is now in O(N), but given
that the values of N are always small, I don't think this is a problem.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-dev: Cleanups
* We no more need to include platform_device.h.
* Delete the to_i2c_dev macro, which is no more used (and no more valid
either.)
* Drop i2c_dev.minor. Now that the minor number always matches the i2c
adapter number, this field is redundant with i2c_dev.adap->nr.
* Delete i2c_dev_get_by_adapter() which is now redundant with
i2c_dev_get_by_minor() for the same reason.
* Drop the local variable dev in i2cdev_attach_adapter(), we can
easily do without it.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Unhide the SMBus controller on the Asus PU-DLS board.
This fixes bug #6763.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Fix the value returned by the i2c-powermac's master_xfer method.
It should return the number of messages processed successfully, but
instead returns the number of data bytes in the first (and only)
processed message.
Also explicitly mention the master_xfer convention so that future
implementations get it right directly.
Signed-off-by: Jean Delvare <[email protected]>
Acked-by: Benjamin Herrenschmidt <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
The scx200_acb i2c bus driver pretends to support SMBus block
transactions, but in fact it implements the more simple I2C block
transactions. Additionally, it lacks sanity checks on the length
of the block transactions, which could lead to a buffer overrun.
This fixes an oops reported by Alexander Atanasov:
http://marc.theaimsgroup.com/?l=linux-kernel&m=114970382125094
Thanks to Ben Gardner for fixing my bugs :)
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Hardware monitoring chips don't have to be on the I2C bus.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-i801: Merge setup function
Merge i801_setup into i801_probe, as it doesn't make much sense to
have them split. This lets us handle errors better. Christopher
Hellwig had been suggesting this back in March 2003 when the driver
was merged.
Also drop two useless debug messages (revision and base address can be
obtained from lspci, procfs or sysfs.)
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-i801: Better pci subsystem integration
Integrate the i2c-i801 driver better with the pci subsystem, by
calling pci_{enable,disable}_device and requesting the I/O region
by BAR rather than direct configuration space access.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-i801: Cleanups
Various cleanups to the i2c-i801 driver:
* Fix documentation file and self file name references.
* i801_setup can be marked __devinit.
* Drop useless error local variable and label in i801_setup.
* Avoid a double PCI configuration register write in some cases.
* Use symbolic names for SMBHSTCFG bits.
* Transmit the error code returned by i801_setup instead of forcing it
to an arbitrary value.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-i801: Remove PCI function check
Remove the PCI function number check when probing devices.
This check is redundant, each function has a separate PCI device
ID, so checking for that ID is sufficient.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-i801: Remove force_addr parameter
Remove the force_addr module parameter. It doesn't appear to ever
have been needed, and PCI resources shouldn't be arbitrarily
changed anyway.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
i2c-i801: Fix block transaction poll loops
Two of the three poll loops have the poll and sleep swapped,
causing an extra sleep to occur after the polled condition is
fulfilled. In practice, this doubles the amount of sleep time for
every block transaction.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
In i2c bus driver scx200_acb, function scx200_acb_probe can be
tagged __init.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
I no more wish to be listed as the maintainer for the smsc47m1 and
w83l785ts drivers. I have no test device, and people will fallback
to me as the general hardware monitoring maintainer anyway.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Reword and complete certain parts of the hwmon sysfs-interface
documentation file. Hopefully this will make things clearer for new
driver authors.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Improve the help text for CONFIG_HWMON to let the users know how they
pick the right hardware monitoring driver(s) for their system.
Also fix a couple typos in the related documentation file and improve
some parts a bit.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
One more motherboard confirmed to have an LM83 temperature sensor chip.
Thanks to Steven Hardy for reporting.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Update the list of systems supported by the hdaps driver:
* Add the "ThinkPad Z60m" entry, reported by Arkadiusz Miskiewicz.
* Add the "ThinkPad H" entry, reported by Frank Gevaerts for some
ThinkPad R52 models (1846AQG).
* Drop the "ThinkPad X41 Tablet" entry, which looks redundant to me.
And a comment update for good measure.
Signed-off-by: Jean Delvare <[email protected]>
Cc: Arkadiusz Miskiewicz <[email protected]>
Cc: Frank Gevaerts <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Add support for the new nForce4 MCP51 (also known as nForce 410 or
430) and nForce4 MCP55 to the i2c-nforce2 driver. Some code changes
were required because the base I/O address registers have changed in
these versions. Standard BARs are now being used, while the original
nForce2 chips used non-standard ones.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Properly document on which systems the i2c-piix4 SMBus driver will
refuse to load. Hopefully this will make it clearer for users, which
were often wondering why their destop or server systems were detected
as laptops.
Closes bug #6429.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Extend the sysfs interface of hardware monitoring chips, by adding
individual alarm and beep files. Contrary to the old aggregated "alarms"
and "beeps" files, individual files constitute a standard way to access
the status information, making it finally possible to implement a
chip-independant hardware monitoring chip access library (once all
drivers have been added this new interface, that is.)
If future drivers need more individual files, the interface will be
extended as needed at the same time these drivers are merged into the
kernel tree.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
The F71805F I/O resource structure needs not be a global variable,
as the platform core allocs its own copy of it anyway.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Add alarms support for the W83627EHF/EHG hardware monitoring chip.
This is based on an earlier patch from Rudolf Marek.
Signed-off-by: Rudolf Marek <[email protected]>
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Do not export the following i2c header files to user space:
* i2c-id.h: These IDs are internal to the kernel and user space
does not need them.
* i2c-algo-ite.h: The driver is broken and planned for removal, so
let's not export it for now. The extra ioctl defined here can
be standardized and moved to i2c-core/i2c-dev if really needed.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: David Woodhouse <[email protected]>
We currently don't handle errors properly when resuming a PCI device:
* In pci_default_resume() we capture the error code returned by
pci_enable_device() but don't pass it up to the caller.
Introduced by commit 95a629657d
* In pci_resume_device(), the errors possibly returned by the driver's
.resume method or by the generic pci_default_resume() function are
ignored.
This patch fixes both issues.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Mixing "depends on I2C" and "select I2C" within the media subsystem
leads to the following problem:
Warning! Found recursive dependency: I2C DVB_BUDGET DVB_BUDGET_PATCH
DVB_AV7110 VIDEO_SAA7146_VV VIDEO_SAA7146 I2C
Signed-off-by: Jean Delvare <[email protected]>
Acked-by: Manu Abraham <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
reference to .init.text: from .text between 'dvb_bt8xx_probe'
(at offset 0x122c) and 'dvb_bt8xx_remove'
reference to .init.text: from .text between 'dvb_bt8xx_probe'
(at offset 0x1267) and 'dvb_bt8xx_remove'
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
We can't pass a string on the stack to request_region. As soon as we
leave the function that stack is gone and the string is lost. Let's
use the same string we identify the i2c_adapter with instead, it's
more simple, more consistent, and just works.
This is the second half of fix to bug #6445.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
The scx200_acb driver shouldn't return failure after initialization
if it successfully registered at least one i2c_adapter, else we are
leaking resources. The driver was OK in that respect up to 2.6.16, a
recent change broke it.
This is part of the fix to bug #6445.
Signed-off-by: Jean Delvare <[email protected]>
Cc: Ben Gardner <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Fix the following warning which happens when OCFS2_FS is enabled but
DEBUG_FS isn't:
fs/ocfs2/dlmglue.c: In function `ocfs2_dlm_init_debug':
fs/ocfs2/dlmglue.c:2036: warning: passing arg 5 of `debugfs_create_file' discards qualifiers from pointer target type
Signed-off-by: Jean Delvare <[email protected]>
Cc: Arjan van de Ven <[email protected]>
Cc: Joel Becker <[email protected]>
Acked-by: Mark Fasheh <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
We could use the recently added PCI_CLASS_SERIAL_USB_UHCI,
PCI_CLASS_SERIAL_USB_OHCI and PCI_CLASS_SERIAL_USB_EHCI defines in
more places, for slightly shorter and clearer code.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Fix for bug #6395:
Fail to resume on Tecra M2 with ADM1032 and Intel 82801DBM
The BIOS of the Tecra M2 doesn't like it when it has to reboot or resume
after the i2c-i801 driver has left the SMBus in PEC mode. The most simple
fix is to clear the PEC bit after after every transaction. That's what
this driver was doing up to 2.6.15 (inclusive).
Thanks to Daniele Gaffuri for the very good report.
Signed-off-by: Jean Delvare <[email protected]>
Cc: Greg KH <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
The Asus A6VA notebook was reported to need a PCI quirk to unhide
the SMBus.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Make the w83792d driver keep quiet when misdetecting a chip. This can
happen, and the user doesn't need to know.
Also renumber the messages, and add one, for consistency.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
A tasklet is not suitable for what the ds1374 driver does: neither sleeping
nor mutex operations are allowed in tasklets, and ds1374_set_tlet may do
both.
We can use a workqueue instead, where both sleeping and mutex operations
are allowed.
Signed-off-by: Jean Delvare <[email protected]>
Acked-by: Randy Vinson <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
A few cleanups which were done to almost all i2c drivers some times
ago, but matroxfb_maven was forgotten:
* Don't allocate two different structures at once.
* Use kzalloc instead of kmalloc+memset.
* Use strlcpy instead of strcpy.
* Drop duplicate error message on client deregistration failure.
Signed-off-by: Jean Delvare <[email protected]>
Acked-by: Petr Vandrovec <[email protected]>
Cc: "Antonino A. Daplas" <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Several media/video and sound drivers include i2c-dev.h while they
don't need it at all. Clean it up.
This header file is really only needed by i2c-dev.c and
compat_ioctl.c, other drivers should never need it.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Drop a redundant mutex in driver i2c-ali1535. The struct i2c_adapter
includes a mutex for the same purpose, operated by i2c-core.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Drop unused rogue i2c driver ID and nonsensical i2c class.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Properly set the name member of the i2c_adapter structure of the ite
i2c adapter driver.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Drop the i2c-frodo bus driver. It isn't referenced by the build
system, and depends on code which was never included in 2.6 kernels.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Stop holding the core_lists mutex when we don't actually need it.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Stop resetting the chip on load by default, so as to preserve the BIOS
initializations. Same was done in the w83627hf driver some times ago
for the same reasons.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Document the individual alarm and beep bits of the w83781d driver.
Ideally we would offer a chip-independant interface for them, but
until it's done, it's only fair that we document the current
interface.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Add support for the Intel Pentium M series to the hwmon-vid driver.
Signed-off-by: Jean Delvare <[email protected]>
Cc: Rudolf Marek <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Add support for the Winbond W83687THF chip to the w83627hf hardware
monitoring driver. This new chip is almost similar to the already
supported W83627THF chip, except for VID and a few other minor
changes.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Convert the new f71805f hardware monitoring driver to use mutexes
instead of semaphores.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Cleanup after the semaphores to mutexes conversions in the i2c
subsystem.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Speed up i2c_smbus_write_block_data and i2c_smbus_read_i2c_block_data
a bit by using memcpy instead of an explicit loop.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Drop 3 useless macros in the w83792d hardware monitoring driver.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
scx200_acb is only useful on a few Geode-based systems, and won't
compile on non-x86 systems due to the lack of asm/msr.h, as reported
by Andrew Morton. Thus, we should make that driver depend on X86.
Signed-off-by: Jean Delvare <[email protected]>
Convert the f71805f driver to use arrays of attributes. This shrinks the
compiled module from 12.0 kB to 9.6 kB. We certainly should do the same
for as many hardware monitoring drivers as possible.
This, together with a nice chip design by Fintek, makes this driver
very small, both in terms of number of lines of code and memory
consumption.
Signed-off-by: Jean Delvare <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>