17 Aug, 2012

1 commit


27 Jul, 2012

1 commit

  • Pull driver core changes from Greg Kroah-Hartman:
    "Here's the big driver core pull request for 3.6-rc1.

    Unlike 3.5, this kernel should be a lot tamer, with the printk changes
    now settled down. All we have here is some extcon driver updates, w1
    driver updates, a few printk cleanups that weren't needed for 3.5, but
    are good to have now, and some other minor fixes/changes in the driver
    core.

    All of these have been in the linux-next releases for a while now.

    Signed-off-by: Greg Kroah-Hartman "

    * tag 'driver-core-3.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (38 commits)
    printk: Export struct log size and member offsets through vmcoreinfo
    Drivers: hv: Change the hex constant to a decimal constant
    driver core: don't trigger uevent after failure
    extcon: MAX77693: Add extcon-max77693 driver to support Maxim MAX77693 MUIC device
    sysfs: fail dentry revalidation after namespace change fix
    sysfs: fail dentry revalidation after namespace change
    extcon: spelling of detach in function doc
    extcon: arizona: Stop microphone detection if we give up on it
    extcon: arizona: Update cable reporting calls and split headset
    PM / Runtime: Do not increment device usage counts before probing
    kmsg - do not flush partial lines when the console is busy
    kmsg - export "continuation record" flag to /dev/kmsg
    kmsg - avoid warning for CONFIG_PRINTK=n compilations
    kmsg - properly print over-long continuation lines
    driver-core: Use kobj_to_dev instead of re-implementing it
    driver-core: Move kobj_to_dev from genhd.h to device.h
    driver core: Move deferred devices to the end of dpm_list before probing
    driver core: move uevent call to driver_register
    driver core: fix shutdown races with probe/remove(v3)
    Extcon: Arizona: Add driver for Wolfson Arizona class devices
    ...

    Linus Torvalds
     

22 Jun, 2012

3 commits

  • Convert the OMAP HDQ driver to use runtime PM. Compile- and boot-tested,
    but not tested in actual use.

    Signed-off-by: Paul Walmsley
    Cc: NeilBrown
    Cc: Evgeniy Polyakov
    Acked-by: Evgeniy Polyakov
    Tested-by: NeilBrown

    Paul Walmsley
     
  • HDQ/1-wire registers are 32 bits long, even if the register contents
    fit into 8 bits, so accesses must be 32-bit aligned. Evidently the
    OMAP2/3 interconnects allowed the driver to get away with 8 bit accesses,
    but the OMAP4 puts a stop to that:

    [ 1.488800] Driver for 1-wire Dallas network protocol.
    [ 1.495025] Bad mode in data abort handler detected
    [ 1.500122] Internal error: Oops - bad mode: 0 [#1] SMP
    [ 1.505615] Modules linked in:
    [ 1.508819] CPU: 0 Not tainted (3.3.0-rc1-00008-g45030e9 #992)
    [ 1.515289] PC is at 0xffff0018
    [ 1.518615] LR is at omap_hdq_probe+0xd4/0x2cc

    The OMAP4430 ES2 Rev X TRM does warn about this restriction in section
    23.2.6.2 "HDQ/1-Wire Registers".

    Fixes the crash on OMAP4430 ES2 Pandaboard. Tested also on OMAP34xx and
    OMAP2420; it seems to work fine on those chips, although due to the lack
    of boards with HDQ/1-wire devices here, a more indepth test was not
    possible.

    Signed-off-by: Paul Walmsley
    Cc: NeilBrown
    Cc: Evgeniy Polyakov
    Acked-by: Evgeniy Polyakov

    Paul Walmsley
     
  • Allow the OMAP HDQ1W driver to be built for all OMAP2+ SoCs by
    adjusting KConfig dependencies. The previous dependency required
    either SOC_OMAP2430 or ARCH_OMAP3 to be set, but the HDQ IP block is
    present on OMAP2420 and OMAP44xx SoCs. The driver was still
    selectable on multi-OMAP kernel configurations, however; so the
    previous prohibition was rather pointless.

    Signed-off-by: Paul Walmsley
    Cc: Evgeniy Polyakov
    Acked-by: Evgeniy Polyakov

    Paul Walmsley
     

19 Jun, 2012

1 commit


14 Jun, 2012

5 commits

  • Signed-off-by: Markus Franke
    Signed-off-by: Greg Kroah-Hartman

    Markus Franke
     
  • The 'mutex' in struct w1_master is use for two very different
    purposes.

    Firstly it protects various data structures such as the list of all
    slaves.

    Secondly it protects the w1 buss against concurrent accesses.

    This can lead to deadlocks when the ->probe code called while adding a
    slave needs to talk on the bus, as is the case for power_supply
    devices.
    ds2780 and ds2781 drivers contain a work around to track which
    process hold the lock simply to avoid this deadlock. bq27000 doesn't
    have that work around and so deadlocks.

    There are other possible deadlocks involving sysfs.
    When removing a device the sysfs s_active lock is held, so the lock
    that protects the slave list must take precedence over s_active.
    However when access power_supply attributes via sysfs, the s_active
    lock must take precedence over the lock that protects accesses to
    the bus.

    So to avoid deadlocks between w1 slaves and sysfs, these must be
    two separate locks. Making them separate means that the work around
    in ds2780 and ds2781 can be removed.

    So this patch:
    - adds a new mutex: "bus_mutex" which serialises access to the bus.
    - takes in mutex in w1_search and ds1wm_search while they access
    the bus for searching. The mutex is dropped before calling the
    callback which adds the slave.
    - changes all slaves to use bus_mutex instead of mutex to
    protect access to the bus
    - removes w1_ds2790_io_nolock and w1_ds2781_io_nolock, and the
    related code from drivers/power/ds278[01]_battery.c which
    calls them.

    Signed-off-by: NeilBrown
    Acked-by: Evgeniy Polyakov
    Signed-off-by: Greg Kroah-Hartman

    NeilBrown
     
  • There is no gain in having a loop - there is no risk of missing the
    interrupt with wait_event_timeout.

    Signed-off-by: NeilBrown
    Acked-by: Evgeniy Polyakov
    Signed-off-by: Greg Kroah-Hartman

    NeilBrown
     
  • - some debug messages missed spaces
    - sometimes no error was returned when it should have been
    - sometimes a message is printed when there is no error, rather
    than when there is one.

    Acked-by: Evgeniy Polyakov
    Signed-off-by: NeilBrown
    Signed-off-by: Greg Kroah-Hartman

    NeilBrown
     
  • This reverts commit 59d4467be405316916a4087d5b02d99196eeef04.

    Turns out it was the wrong version, will apply the correct version after
    this.

    Reported-by: NeilBrown
    Cc: Evgeniy Polyakov
    Cc: Andrew Morton
    Signed-off-by: Greg Kroah-Hartman

    Greg Kroah-Hartman
     

13 Jun, 2012

2 commits

  • There were some return statements around in the w1_uevent, used goto
    to cleanup those return statements with the help of err variable,
    and also removed a semi colon at the end of the w1_uevent's closing
    brace.

    Signed-off-by: Devendra Naga
    Acked-by: Evgeniy Polyakov
    Signed-off-by: Greg Kroah-Hartman

    Devendra Naga
     
  • w1 devices need a mutex to serial IO. Most use master->mutex.
    However that is used for other purposes and they can conflict.

    In particular master->mutex is held while w1_attach_slave_device is
    called.

    For bq27000, this registers a 'powersupply' device which tries to read the
    current status. The attempt to read will cause a deadlock on
    master->mutex.

    So create a new per-slave mutex and use that for serializing IO for
    bq27000.

    Signed-off-by: NeilBrown
    Cc: Evgeniy Polyakov
    Signed-off-by: Andrew Morton
    Signed-off-by: Greg Kroah-Hartman

    NeilBrown
     

27 May, 2012

1 commit

  • Pull arm-soc clock driver changes from Olof Johansson:
    "The new clock subsystem was merged in linux-3.4 without any users,
    this now moves the first three platforms over to it: imx, mxs and
    spear.

    The series also contains the changes for the clock subsystem itself,
    since Mike preferred to have it together with the platforms that
    require these changes, in order to avoid interdependencies and
    conflicts."

    Fix up trivial conflicts in arch/arm/mach-kirkwood/common.c (code
    removed in one branch, added OF support in another) and
    drivers/dma/imx-sdma.c (independent changes next to each other).

    * tag 'clock' of git://git.kernel.org/pub/scm/linux/kernel/git/arm/arm-soc: (97 commits)
    clk: Fix CLK_SET_RATE_GATE flag validation in clk_set_rate().
    clk: Provide dummy clk_unregister()
    SPEAr: Update defconfigs
    SPEAr: Add SMI NOR partition info in dts files
    SPEAr: Switch to common clock framework
    SPEAr: Call clk_prepare() before calling clk_enable
    SPEAr: clk: Add General Purpose Timer Synthesizer clock
    SPEAr: clk: Add Fractional Synthesizer clock
    SPEAr: clk: Add Auxiliary Synthesizer clock
    SPEAr: clk: Add VCO-PLL Synthesizer clock
    SPEAr: Add DT bindings for SPEAr's timer
    ARM i.MX: remove now unused clock files
    ARM: i.MX6: implement clocks using common clock framework
    ARM i.MX35: implement clocks using common clock framework
    ARM i.MX5: implement clocks using common clock framework
    ARM: Kirkwood: Replace clock gating
    ARM: Orion: Audio: Add clk/clkdev support
    ARM: Orion: PCIE: Add support for clk
    ARM: Orion: XOR: Add support for clk
    ARM: Orion: CESA: Add support for clk
    ...

    Linus Torvalds
     

23 May, 2012

1 commit

  • Pull trivial updates from Jiri Kosina:
    "As usual, it's mostly typo fixes, redundant code elimination and some
    documentation updates."

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (57 commits)
    edac, mips: don't change code that has been removed in edac/mips tree
    xtensa: Change mail addresses of Hannes Weiner and Oskar Schirmer
    lib: Change mail address of Oskar Schirmer
    net: Change mail address of Oskar Schirmer
    arm/m68k: Change mail address of Sebastian Hess
    i2c: Change mail address of Oskar Schirmer
    net: Fix tcp_build_and_update_options comment in struct tcp_sock
    atomic64_32.h: fix parameter naming mismatch
    Kconfig: replace "--- help ---" with "---help---"
    c2port: fix bogus Kconfig "default no"
    edac: Fix spelling errors.
    qla1280: Remove redundant NULL check before release_firmware() call
    remoteproc: remove redundant NULL check before release_firmware()
    qla2xxx: Remove redundant NULL check before release_firmware() call.
    aic94xx: Get rid of redundant NULL check before release_firmware() call
    tehuti: delete redundant NULL check before release_firmware()
    qlogic: get rid of a redundant test for NULL before call to release_firmware()
    bna: remove redundant NULL test before release_firmware()
    tg3: remove redundant NULL test before release_firmware() call
    typhoon: get rid of redundant conditional before all to release_firmware()
    ...

    Linus Torvalds
     

07 May, 2012

1 commit

  • There are three Kconfig entries with "--- help ---" attributes, and over
    2000 Kconfig entries with "---help---" attributes. Apparently the three
    attributes with embedded spaces are valid. Still, I see little reason
    for using this obscure variant. And replacing those three attributes
    with the common variant makes grepping Kconfig files for help texts a
    bit easier too.

    Signed-off-by: Paul Bolle
    Signed-off-by: Jiri Kosina

    Paul Bolle
     

05 May, 2012

1 commit


30 Apr, 2012

1 commit


25 Apr, 2012

1 commit


19 Apr, 2012

1 commit


12 Apr, 2012

2 commits


10 Apr, 2012

1 commit


09 Apr, 2012

1 commit


03 Apr, 2012

1 commit


09 Mar, 2012

1 commit


25 Feb, 2012

3 commits


16 Feb, 2012

1 commit

  • w1_bq27000 adds a bq27000-battery platform device but does not provide
    platform data for it. This causes the bq27x00 driver to dereference a NULL
    pointer.
    So provide the appropriate platform data. This requires modifying
    w1_bq27000_read so that it find the w1 device as the parent of the bq device.

    Also there is no point exporting w1_bq27000_read as nothing else uses it
    or could use it. So make it static.

    Finally, as there is no way to track how many batteries have been found, and
    we will probably only find one, use an id number of '-1' to assert that this
    is a unique instance.

    Signed-off-by: NeilBrown
    Tested-by: Thomas Weber
    Acked-by: Evgeniy Polyakov
    Signed-off-by: Greg Kroah-Hartman

    NeilBrown
     

10 Feb, 2012

1 commit


10 Dec, 2011

1 commit

  • This enables a much more efficient way of device searching. It uses the
    1-wire read-rom operation which allows the direct reading of the slave
    address. BUT this works only with exactly one slave on the bus.

    Signed-off-by: Hubert Feurstein
    Acked-by: Evgeniy Polyakov

    index c374978..9761950 100644
    Signed-off-by: Greg Kroah-Hartman

    Evgeniy Polyakov
     

19 Nov, 2011

1 commit

  • This converts the remaining USB drivers in the kernel to use the
    module_usb_driver() macro which makes the code smaller and a bit
    simpler.

    Added bonus is that it removes some unneeded kernel log messages about
    drivers loading and/or unloading.

    Cc: Guenter Roeck
    Cc: Jean Delvare
    Cc: Ben Dooks
    Cc: Till Harbaum
    Cc: Karsten Keil
    Cc: Chris Ball
    Cc: David Woodhouse
    Cc: Lauro Ramos Venancio
    Cc: Aloisio Almeida Jr
    Cc: Samuel Ortiz
    Cc: Steve Glendinning
    Cc: Florian Tobias Schandinat
    Cc: Evgeniy Polyakov
    Cc: Wim Van Sebroeck
    Cc: "David S. Miller"
    Cc: Jesper Juhl
    Cc: Artem Bityutskiy
    Cc: Jamie Iles
    Cc: Andrew Morton
    Signed-off-by: Greg Kroah-Hartman

    Greg Kroah-Hartman
     

18 Nov, 2011

1 commit

  • w1_therm devices can either be bus powered or externally powered.

    When device is bus powered during temperature conversion the bus
    have to be left high to provide necessary power. Some masters also allow
    strong power-up to be enabled in this case.
    Naturally, no communication over bus can occur during that time.

    However, if device has external power then there is no such restriction,
    and host can talk to other devices during temperature conversion.

    There is command which allows us to check how device is powered,
    this patch uses it to release the bus on externally w1_therm powered devices
    during temperature conversion.

    Also, this changes uninterruptible sleeps there into interruptible ones to
    avoid long uninterruptible sleep if w1 subsystem happens to grab bus for
    scan during w1_therm_read().

    Signed-off-by: Maciej Szmigiero
    Acked-by: Evgeniy Polyakov
    Signed-off-by: Greg Kroah-Hartman

    Maciej Szmigiero
     

07 Nov, 2011

1 commit

  • * 'modsplit-Oct31_2011' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux: (230 commits)
    Revert "tracing: Include module.h in define_trace.h"
    irq: don't put module.h into irq.h for tracking irqgen modules.
    bluetooth: macroize two small inlines to avoid module.h
    ip_vs.h: fix implicit use of module_get/module_put from module.h
    nf_conntrack.h: fix up fallout from implicit moduleparam.h presence
    include: replace linux/module.h with "struct module" wherever possible
    include: convert various register fcns to macros to avoid include chaining
    crypto.h: remove unused crypto_tfm_alg_modname() inline
    uwb.h: fix implicit use of asm/page.h for PAGE_SIZE
    pm_runtime.h: explicitly requires notifier.h
    linux/dmaengine.h: fix implicit use of bitmap.h and asm/page.h
    miscdevice.h: fix up implicit use of lists and types
    stop_machine.h: fix implicit use of smp.h for smp_processor_id
    of: fix implicit use of errno.h in include/linux/of.h
    of_platform.h: delete needless include
    acpi: remove module.h include from platform/aclinux.h
    miscdevice.h: delete unnecessary inclusion of module.h
    device_cgroup.h: delete needless include
    net: sch_generic remove redundant use of
    net: inet_timewait_sock doesnt need
    ...

    Fix up trivial conflicts (other header files, and removal of the ab3550 mfd driver) in
    - drivers/media/dvb/frontends/dibx000_common.c
    - drivers/media/video/{mt9m111.c,ov6650.c}
    - drivers/mfd/ab3550-core.c
    - include/linux/dmaengine.h

    Linus Torvalds
     

03 Nov, 2011

4 commits

  • Interrupting w1_delay() in w1_read_bit() results in missing the low level
    on the w1 line and receiving "1" instead of "0".

    Add local_irq_save()/local_irq_restore() around the critical section

    Signed-off-by: Jan Weitzel
    Acked-by: Evgeniy Polyakov
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jan Weitzel
     
  • When using multiple masters, w1_int.c would use the .init_name from w1.c
    for all entities, which will fail when creating a corresponding sysfs
    entry. This patch uses the unique name previously generated.

    WARNING: at fs/sysfs/dir.c:451 sysfs_add_one+0x48/0x64()
    sysfs: cannot create duplicate filename '/devices/w1 bus master'
    Modules linked in:
    Call trace:
    [] warn_slowpath_common+0x34/0x44
    [] warn_slowpath_fmt+0x14/0x18
    [] sysfs_add_one+0x48/0x64
    [] create_dir+0x40/0x68
    [] sysfs_create_dir+0x66/0x78
    [] kobject_add_internal+0x6e/0x104
    [] kobject_add_varg+0x20/0x2c
    [] kobject_add+0x30/0x3c
    [] device_add+0x6a/0x378
    [] device_initialize+0x12/0x48
    [] device_register+0xc/0x10
    [] w1_add_master_device+0x162/0x274
    [] w1_gpio_probe+0x66/0xb4
    [] kernel_init+0x0/0xe8
    [] platform_drv_probe+0xc/0xe
    [] kernel_init+0x0/0xe8
    [] driver_probe_device+0x6c/0xdc
    [] __driver_attach+0x34/0x48
    [] bus_for_each_dev+0x2c/0x48
    [] __driver_attach+0x0/0x48
    [] driver_attach+0x10/0x14
    [] bus_add_driver+0x6a/0x18c
    [] driver_register+0x60/0xb8
    [] __initcall_w1_therm_init6+0x0/0x4
    [] w1_gpio_init+0x0/0x14
    [] kernel_init+0x0/0xe8
    [] platform_driver_register+0x30/0x38
    [] __initcall_w1_therm_init6+0x0/0x4
    [] w1_gpio_init+0x0/0x14
    [] kernel_init+0x0/0xe8
    [] platform_driver_probe+0xe/0x3c
    [] w1_gpio_init+0xc/0x14
    [] __initcall_w1_therm_init6+0x0/0x4
    [] w1_gpio_init+0x0/0x14
    [] do_one_initcall+0x34/0x130
    [] kernel_init+0x66/0xe8
    [] __initcall_w1_therm_init6+0x0/0x4
    [] do_exit+0x0/0x3a6
    [] kernel_init+0x0/0xe8
    [] do_exit+0x0/0x3a6

    ---[ end trace 5a9233884fead918 ]---
    kobject_add_internal failed for w1 bus master with -EEXIST, don't try to register things with the same name in the same directory.

    Signed-off-by: Florian Faber
    Cc: Evgeniy Polyakov
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Florian Faber
     
  • Adds a nolock function to the w1 interface to avoid locking the
    mutex if needed.

    Signed-off-by: Clifton Barnes
    Cc: Evgeniy Polyakov
    Cc:
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Clifton Barnes
     
  • Straightforward. As an aside, the ida_init calls are not needed as far as
    I can see needed. (DEFINE_IDA does the same already).

    Signed-off-by: Jonathan Cameron
    Cc: Evgeniy Polyakov
    Acked-by: Clifton Barnes
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jonathan Cameron
     

01 Nov, 2011

1 commit