diff options
author | Tony Lindgren <tony@atomide.com> | 2011-11-07 21:27:23 +0100 |
---|---|---|
committer | Tony Lindgren <tony@atomide.com> | 2011-11-07 21:27:23 +0100 |
commit | d30cc16c8e48368e0518f4975a78711e53e14a0f (patch) | |
tree | 26b57f7ab5a963cc3d6c57dff6951bd930875583 /drivers/w1/w1_io.c | |
parent | ARM: OMAP2: Fix H4 matrix keyboard warning (diff) | |
parent | ARM: OMAP: Fix export.h or module.h includes (diff) | |
download | linux-d30cc16c8e48368e0518f4975a78711e53e14a0f.tar.xz linux-d30cc16c8e48368e0518f4975a78711e53e14a0f.zip |
Merge branch 'fixes-modulesplit' into fixes
Diffstat (limited to 'drivers/w1/w1_io.c')
-rw-r--r-- | drivers/w1/w1_io.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/w1/w1_io.c b/drivers/w1/w1_io.c index 765b37b62a4f..3135b2c63998 100644 --- a/drivers/w1/w1_io.c +++ b/drivers/w1/w1_io.c @@ -158,13 +158,18 @@ EXPORT_SYMBOL_GPL(w1_write_8); static u8 w1_read_bit(struct w1_master *dev) { int result; + unsigned long flags; + /* sample timing is critical here */ + local_irq_save(flags); dev->bus_master->write_bit(dev->bus_master->data, 0); w1_delay(6); dev->bus_master->write_bit(dev->bus_master->data, 1); w1_delay(9); result = dev->bus_master->read_bit(dev->bus_master->data); + local_irq_restore(flags); + w1_delay(55); return result & 0x1; |