- Oct 27, 2010
-
-
Brian Swetland authored
The search/pullup/add/remove device attributes were 0666 which would allow arbitrary users to affect the 1 wire bus. Change to 0664 to prevent that. I found this patch in the Android tree, apparently this has never been sent upstream so doing it now. Signed-off-by:
Brian Swetland <swetland@google.com> Signed-off-by:
Linus Walleij <linus.walleij@stericsson.com> Cc: Evgeniy Polyakov <johnpol@2ka.mipt.ru> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- May 21, 2010
-
-
Chris Wright authored
This allows bin_attr->read,write,mmap callbacks to check file specific data (such as inode owner) as part of any privilege validation. Signed-off-by:
Chris Wright <chrisw@sous-sol.org> Signed-off-by:
Greg Kroah-Hartman <gregkh@suse.de>
-
- Apr 24, 2010
-
-
Amit Kucheria authored
Fixes the following error: drivers/w1/masters/omap_hdq.c: In function 'hdq_wait_for_flag': drivers/w1/masters/omap_hdq.c:137: error: implicit declaration of function 'schedule_timeout_uninterruptible' drivers/w1/masters/omap_hdq.c: In function 'hdq_write_byte': drivers/w1/masters/omap_hdq.c:177: error: 'TASK_UNINTERRUPTIBLE' undeclared (first use in this function) drivers/w1/masters/omap_hdq.c:177: error: (Each undeclared identifier is reported only once drivers/w1/masters/omap_hdq.c:177: error: for each function it appears in.) drivers/w1/masters/omap_hdq.c:177: error: implicit declaration of function 'schedule_timeout' drivers/w1/masters/omap_hdq.c: In function 'hdq_isr': drivers/w1/masters/omap_hdq.c:221: error: 'TASK_NORMAL' undeclared (first use in this function) drivers/w1/masters/omap_hdq.c: In function 'omap_hdq_break': drivers/w1/masters/omap_hdq.c:316: error: 'TASK_UNINTERRUPTIBLE' undeclared (first use in this function) Signed-off-by:
Amit Kucheria <amit.kucheria@canonical.com> Acked-by:
Tony Lindgren <tony@atomide.com> Cc: Evgeniy Polyakov <johnpol@2ka.mipt.ru> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Ian Dall authored
Fix regression caused by commit 507e2fba ("w1: w1 temp calculation overflow fix") whereby negative temperatures for the DS18B20 are not converted properly. When the temperature exceeds 32767 milli-degrees the temperature overflows to -32768 millidegrees. These are both well within the -55 - +125 degree range for the sensor. Addresses https://bugzilla.kernel.org/show_bug.cgi?id=12646 Signed-of-by:
Ian Dall <ian@beware.dropbear.id.au> Cc: Evgeniy Polyakov <johnpol@2ka.mipt.ru> Tested-by:
Karsten Elfenbein <kelfe@gmx.de> Cc: <stable@kernel.org> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Mar 30, 2010
-
-
Tejun Heo authored
include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h percpu.h is included by sched.h and module.h and thus ends up being included when building most .c files. percpu.h includes slab.h which in turn includes gfp.h making everything defined by the two files universally available and complicating inclusion dependencies. percpu.h -> slab.h dependency is about to be removed. Prepare for this change by updating users of gfp and slab facilities include those headers directly instead of assuming availability. As this conversion needs to touch large number of source files, the following script is used as the basis of conversion. http://userweb.kernel.org/~tj/misc/slabh-sweep.py The script does the followings. * Scan files for gfp and slab usages and update includes such that only the necessary includes are there. ie. if only gfp is used, gfp.h, if slab is used, slab.h. * When the script inserts a new include, it looks at the include blocks and try to put the new include such that its order conforms to its surrounding. It's put in the include block which contains core kernel includes, in the same order that the rest are ordered - alphabetical, Christmas tree, rev-Xmas-tree or at the end if there doesn't seem to be any matching order. * If the script can't find a place to put a new include (mostly because the file doesn't have fitting include block), it prints out an error message indicating which .h file needs to be added to the file. The conversion was done in the following steps. 1. The initial automatic conversion of all .c files updated slightly over 4000 files, deleting around 700 includes and adding ~480 gfp.h and ~3000 slab.h inclusions. The script emitted errors for ~400 files. 2. Each error was manually checked. Some didn't need the inclusion, some needed manual addition while adding it to implementation .h or embedding .c file was more appropriate for others. This step added inclusions to around 150 files. 3. The script was run again and the output was compared to the edits from #2 to make sure no file was left behind. 4. Several build tests were done and a couple of problems were fixed. e.g. lib/decompress_*.c used malloc/free() wrappers around slab APIs requiring slab.h to be added manually. 5. The script was run on all .h files but without automatically editing them as sprinkling gfp.h and slab.h inclusions around .h files could easily lead to inclusion dependency hell. Most gfp.h inclusion directives were ignored as stuff from gfp.h was usually wildly available and often used in preprocessor macros. Each slab.h inclusion directive was examined and added manually as necessary. 6. percpu.h was updated not to include slab.h. 7. Build test were done on the following configurations and failures were fixed. CONFIG_GCOV_KERNEL was turned off for all tests (as my distributed build env didn't work with gcov compiles) and a few more options had to be turned off depending on archs to make things build (like ipr on powerpc/64 which failed due to missing writeq). * x86 and x86_64 UP and SMP allmodconfig and a custom test config. * powerpc and powerpc64 SMP allmodconfig * sparc and sparc64 SMP allmodconfig * ia64 SMP allmodconfig * s390 SMP allmodconfig * alpha SMP allmodconfig * um on x86_64 SMP allmodconfig 8. percpu.h modifications were reverted so that it could be applied as a separate patch and serve as bisection point. Given the fact that I had only a couple of failures from tests on step 6, I'm fairly confident about the coverage of this conversion patch. If there is a breakage, it's likely to be something in one of the arch headers which should be easily discoverable easily on most builds of the specific arch. Signed-off-by:
Tejun Heo <tj@kernel.org> Guess-its-ok-by:
Christoph Lameter <cl@linux-foundation.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
-
- Mar 12, 2010
-
-
Alberto Panizzo authored
This fixes the section mismatch warning for mxc_w1_probe() Cc: Evgeniy Polyakov <johnpol@2ka.mipt.ru> Cc: Sascha Hauer <s.hauer@pengutronix.de> Acked-by:
Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Roel Kluin authored
With `while (++retries < DS2482_WAIT_IDLE_TIMEOUT)' retries reaches DS2482_WAIT_IDLE_TIMEOUT after the loop Signed-off-by:
Roel Kluin <roel.kluin@gmail.com> Cc: Evgeniy Polyakov <johnpol@2ka.mipt.ru> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Mar 07, 2010
-
-
Uwe Kleine-König authored
A pointer to omap_hdq_probe is passed to the core via platform_driver_register and so the function must not disappear when the .init sections are discarded. Otherwise (if also having HOTPLUG=y) unbinding and binding a device to the driver via sysfs will result in an oops as does a device being registered late. An alternative to this patch is using platform_driver_probe instead of platform_driver_register plus removing the pointer to the probe function from the struct platform_driver. Signed-off-by:
Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Cc: Stanley.Miao <stanley.miao@windriver.com> Acked-by:
Evgeniy Polyakov <zbr@ioremap.net> Cc: Andrew Morton <akpm@linux-foundation.org> Cc: Madhusudhan Chikkature <madhu.cr@ti.com> Cc: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by:
Greg Kroah-Hartman <gregkh@suse.de>
-
- Feb 15, 2010
-
-
Tony Lindgren authored
Replace ARCH_OMAP34XX with ARCH_OMAP3 Signed-off-by:
Tony Lindgren <tony@atomide.com>
-
- Feb 05, 2010
-
-
Peter Huewe authored
Trivial patch which adds the __init/__exit macros to the module_init/ module_exit functions of drivers/w1/w1.c Signed-off-by:
Peter Huewe <peterhuewe@gmx.de> Signed-off-by:
Jiri Kosina <jkosina@suse.cz>
-
- Oct 04, 2009
-
-
Jean Delvare authored
There is no point in implementing a detect callback for the DS2482, as this device can't be detected. It was there solely to handle "force" module parameters to instantiate devices, but now we have a better sysfs interface that can do the same. So we can get rid of the ugly module parameters and the detect callback. This shrinks the binary module size by 21%. Signed-off-by:
Jean Delvare <khali@linux-fr.org> Acked-by:
Ben Gardner <gardner.ben@gmail.com>
-
- Oct 02, 2009
-
-
Philipp Reisner authored
Signed-off-by:
Philipp Reisner <philipp.reisner@linbit.com> Acked-by:
Lars Ellenberg <lars.ellenberg@linbit.com> Acked-by:
Evgeniy Polyakov <zbr@ioremap.net> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- Aug 07, 2009
-
-
Stoyan Gaydarov authored
This was found using a semantic patch, more info can be found at: http://www.emn.fr/x-info/coccinelle/ Signed-off-by:
Stoyan Gaydarov <sgayda2@uiuc.edu> Acked-by:
Evgeniy Polyakov <johnpol@2ka.mipt.ru> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Jul 17, 2009
-
-
Mike Frysinger authored
The connector documentation states that the argument to the callback function is always a pointer to a struct cn_msg, but rather than encode it in the API itself, it uses a void pointer everywhere. This doesn't make much sense to encode the pointer in documentation as it prevents proper C type checking from occurring and can easily allow people to use the wrong pointer type. So convert the argument type to an explicit struct cn_msg pointer. Signed-off-by:
Mike Frysinger <vapier@gentoo.org> Signed-off-by:
David S. Miller <davem@davemloft.net>
-
- Jun 18, 2009
-
-
Daniel Mack authored
On embedded devices, sleep mode conditions can be tricky to handle, Especially when processors tend to pull-down the w1 bus during sleep. Bus slaves (such as the ds2760) may interpret this as a reason for power-down conditions and entirely switch off the device. This patch adds a callback function pointer to let users switch on and off the external pull-up resistor. This lets the outside world know whether the processor is currently actively driving the bus or not. When this callback is not provided, the code behaviour won't change. Signed-off-by:
Daniel Mack <daniel@caiaq.de> Acked-by:
Ville Syrjala <syrjala@sci.fi> Acked-by:
Evgeniy Polyakov <johnpol@2ka.mipt.ru> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Jun 12, 2009
-
-
Pavel Machek authored
.ko is normally not included in Kconfig help, make it consistent. Signed-off-by:
Pavel Machek <pavel@ucw.cz> Signed-off-by:
Jiri Kosina <jkosina@suse.cz>
-
- Jun 08, 2009
-
-
Daniel Mack authored
This adds support for ds2760's sleep mode feature. With this feature enabled, the chip enters a deep sleep mode and disconnects from the battery when the w1 line is held down for more than 2 seconds. This new behaviour can be switched on and off using a new module parameter. Signed-off-by:
Daniel Mack <daniel@caiaq.de> Cc: Szabolcs Gyurko <szabolcs.gyurko@tlt.hu> Acked-by:
Matt Reimer <mreimer@vpop.net> Acked-by:
Evgeniy Polyakov <zbr@ioremap.net> Signed-off-by:
Anton Vorontsov <cbouatmailru@gmail.com>
-
Daniel Mack authored
In order to modify the DS2762's status registers and to add support for sleep mode, there is need for functions to write the internal EEPROM. Signed-off-by:
Daniel Mack <daniel@caiaq.de> Acked-by:
Matt Reimer <mreimer@vpop.net> Acked-by:
Szabolcs Gyurko <szabolcs.gyurko@tlt.hu> Acked-by:
Evgeniy Polyakov <zbr@ioremap.net> Signed-off-by:
Anton Vorontsov <cbouatmailru@gmail.com>
-
- Apr 04, 2009
-
-
Philipp Zabel authored
This driver requests a clock that usually is supplied by the MFD in which the DS1WM is contained. Currently, it is impossible for a MFD to register their clocks with the generic clock API due to different implementations across architectures. For now, this patch removes the clock handling from DS1WM altogether, trusting that the MFD enable/disable functions will switch the clock if needed. The clock rate is obtained from a new parameter in driver_data. Signed-off-by:
Philipp Zabel <philipp.zabel@gmail.com> Signed-off-by:
Samuel Ortiz <sameo@openedhand.com>
-
Philipp Zabel authored
This patch converts the DS1WM driver into an MFD cell. It also calculates the bus_shift parameter from the memory resource size. Signed-off-by:
Philipp Zabel <philipp.zabel@gmail.com> Signed-off-by:
Samuel Ortiz <sameo@openedhand.com>
-
- Apr 02, 2009
-
-
Daniel Mack authored
This fixes a number of coding style issues I stubled over. Acked-by:
Evgeniy Polyakov <johnpol@2ka.mipt.ru> Signed-off-by:
Daniel Mack <daniel@caiaq.de> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Mar 13, 2009
-
-
Sascha Hauer authored
The context makes it clear already that these are clocks, so there's no need for such a suffix. This patch only changes the clocks actually used in the tree. The remaining clocks are renamed in the subsequent architecture specific patches. Signed-off-by:
Sascha Hauer <s.hauer@pengutronix.de>
-
- Mar 12, 2009
-
-
Daniel Mack authored
W1 master implementations are expected to return 0 or 1 from their read_bit() function. However, not all platforms do return these values from gpio_get_value() - namely PXAs won't. Hence the w1 gpio-master needs to break the result down to 0 or 1 itself. Signed-off-by:
Daniel Mack <daniel@caiaq.de> Cc: Ville Syrjala <syrjala@sci.fi> Cc: Evgeniy Polyakov <johnpol@2ka.mipt.ru> Cc: David Brownell <david-b@pacbell.net> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Feb 27, 2009
-
-
Herton Ronaldo Krzesinski authored
Signed-off-by:
Herton Ronaldo Krzesinski <herton@mandriva.com.br> Acked-by:
Evgeniy Polyakov <zbr@ioremap.net> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Ben Gardner authored
The w1_ds2433 driver does not read from the hardware if the CRC was valid on the last read. The validcrc flag should be cleared after a write so that the new value can be read. Signed-off-by:
Ben Gardner <gardner.ben@gmail.com> Signed-off-by:
Evgeniy Polyakov <johnpol@2ka.mipt.ru> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Feb 11, 2009
-
-
Ian Dall authored
Addresses http://bugzilla.kernel.org/show_bug.cgi?id=12646 When the temperature exceeds 32767 milli-degrees the temperature overflows to -32768 millidegrees. These are bothe well within the -55 - +125 degree range for the sensor. Fix overflow in left-shift of a u8. Signed-off-by:
Ian Dall <ian@beware.dropbear.id.au> Signed-off-by:
Evgeniy Polyakov <zbr@ioremap.net> Cc: <stable@kernel.org> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Feb 08, 2009
-
-
Russell King authored
Signed-off-by:
Russell King <rmk+kernel@arm.linux.org.uk>
-
- Jan 08, 2009
-
-
Evgeniy Polyakov authored
Send completion status of the commands to the userspace. Message and protocol are described in the documentation. Signed-off-by:
Evgeniy Polyakov <zbr@ioremap.net> Cc: Paul Alfille <paul.alfille@gmail.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Evgeniy Polyakov authored
Command which allows to reset the bus. Signed-off-by:
Evgeniy Polyakov <zbr@ioremap.net> Cc: Paul Alfille <paul.alfille@gmail.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Evgeniy Polyakov authored
Signed-off-by:
Evgeniy Polyakov <zbr@ioremap.net> Cc: Paul Alfille <paul.alfille@gmail.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Evgeniy Polyakov authored
This small patchset extendes existing commands with reset, master IO and status messages. Reset is used to reset the bus for given master device, master IO command allows to initiate IO against bus itself not selecting slave device first, which can be used to probe the device for example. And status messages carry command completion status back to the userspace (namely very useful to get -ENODEV from when requested device was not found). Great thanks to Paul Alfille of OWFS for testing and commands suggestions. This patch: Allow starting of IO not against already found slave devices, but against the bus itself, which can be used for example to probe devices. [akpm@linux-foundation.org: reindent switch statements] Signed-off-by:
Evgeniy Polyakov <zbr@ioremap.net> Cc: Paul Alfille <paul.alfille@gmail.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Evgeniy Polyakov authored
Initiates search (or alarm search) and returns all found devices to userspace. Found devices are not added into the system (i.e. they are not attached to family devices or bus masters), it will be done via (if was not done yet) usual timed searching. Signed-off-by:
Evgeniy Polyakov <zbr@ioremap.net> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Evgeniy Polyakov authored
Writes and returns sampled data back to userspace. Signed-off-by:
Evgeniy Polyakov <zbr@ioremap.net> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Evgeniy Polyakov authored
This patch series introduces and extends several userspace commands used with netlink protocol. Touch block command allows to write data and return sampled data to the userspace. Extended search and alarm seach commands to return list of slave devices found during given search. List masters command allows to send all registered master IDs to the userspace. Great thanks to Paul Alfille (owfs) who tested this implementation and wrote w1-to-network daemon http://sourceforge.net/projects/w1repeater/ and Frederik Deweerdt and Randy Dunlap for review. This patch: Returns list of registered bus master devices. Signed-off-by:
Evgeniy Polyakov <zbr@ioremap.net> Cc: Paul Alfille <paul.alfille@gmail.com> Cc: Frederik Deweerdt <frederik.deweerdt@xprog.eu> Cc: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Sascha Hauer authored
This patch adds support for the 1-wire master interface for i.MX27 and i.MX31. Signed-off-by:
Luotao Fu <l.fu@pengutronix.de> Signed-off-by:
Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by:
Evgeniy Polyakov <zbr@ioremap.net> Cc: Russell King <rmk@arm.linux.org.uk> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Jan 06, 2009
-
-
Kay Sievers authored
CC: Evgeniy Polyakov <johnpol@2ka.mipt.ru> Signed-off-by:
Kay Sievers <kay.sievers@vrfy.org> Signed-off-by:
Greg Kroah-Hartman <gregkh@suse.de>
-
- Dec 23, 2008
-
-
Evgeniy Polyakov authored
During test of the w1-gpio driver i found that in "w1.c:679 w1_slave_found()" the device id is converted to little-endian with "cpu_to_le64()", but its not converted back to cpu format in "w1_io.c:293 w1_reset_select_slave()". Based on a patch created by Andreas Hummel. [akpm@linux-foundation.org: remove unneeded cast] Reported-by:
Andreas Hummel <andi_hummel@gmx.de> Signed-off-by:
Evgeniy Polyakov <zbr@ioremap.net> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Nov 30, 2008
-
-
Al Viro authored
Uses clk_...() a lot Acked-by:
<rmk+kernel@arm.linux.org.uk> Signed-off-by:
Al Viro <viro@zeniv.linux.org.uk> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Nov 19, 2008
-
-
Stanley.Miao authored
OMAP LDP boot crash. This is because w1 subsystem changed the search interface, so update omap_hdq's search interface to follow the change. Signed-off-by:
Stanley.Miao <stanley.miao@windriver.com> Signed-off-by:
Evgeniy Polyakov <zbr@ioremap.net> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Nov 12, 2008
-
-
Madhusudhan Chikkature authored
Provide the BQ27000 slave interface driver. Signed-off-by:
Madhusudhan <Chikkature<madhu.cr@ti.com> Acked-by:
Evgeniy Polyakov <johnpol@2ka.mipt.ru> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-