06 Sep, 2005

13 commits

  • The 24RF08 corruption would better be prevented at i2c-core level than
    at chip driver level, for several reasons:
    * The second quick write should happen as soon as possible after the
    first one, so as to limit the risk that another command is issued on
    the bus inbetween, causing the corruption.
    * As a matter of fact, the protection code at driver level was reworked
    at least three times already, which proves how hard it is to get it
    right there, while it's straightforward at i2c-core level.
    * It's easy to add a new driver that would need the protection, and
    forget to add it. This did happen already.
    * As additional probing addresses can be passed to most i2c chip drivers
    as module parameters, virtually every i2c chip driver would need the
    protection if we want to be really safe.
    * Why duplicate code when we can easily avoid it?

    Signed-off-by: Jean Delvare
    Signed-off-by: Greg Kroah-Hartman

    Jean Delvare
     
  • i2c_probe was quite complex and slow, so I rewrote it in a more
    efficient and hopefully clearer way.

    Note that this slightly changes the way the module parameters are
    handled. This shouldn't change anything for the most common cases
    though.

    For one thing, the function now respects the order of the parameters
    for address probing. It used to always do lower addresses first. The
    new approach gives the user more control.

    For another, ignore addresses don't overrule probe addresses anymore.
    This could have been restored the way it was at the cost of a few more
    lines of code, but I don't think it's worth it. Both lists are given
    as module parameters, so a user would be quite silly to specify the
    same addresses in both lists. The normal addresses list is the only
    one that isn't controlled by a module parameter, thus is the only one
    the user may reasonably want to remove an address from.

    Another significant change is the fact that i2c_probe() will no more
    stop when a detection function returns -ENODEV. Just because a driver
    found a chip it doesn't support isn't a valid reason to stop all
    probings for this one driver. This closes the long standing lm_sensors
    ticket #1807.

    http://www2.lm-sensors.nu/~lm78/readticket.cgi?ticket=1807

    I updated the documentation accordingly.

    In terms of algorithmic complexity, the new code is way better. If
    I is the ignore address count, P the probe address count, N the
    normal address count and F the force address count, the old code
    was doing 128 * (F + I + P + N) iterations max, while the new code
    does F + P + ((I+1) * N) iterations max. For the most common case
    where F, I and P are empty, this is down from 128 * N to N.

    Signed-off-by: Jean Delvare
    Signed-off-by: Greg Kroah-Hartman

    Jean Delvare
     
  • The only part left in i2c-sensor is the VRM/VRD/VID handling code.
    This is in no way related to i2c, so it doesn't belong there. Move
    the code to hwmon, where it belongs.

    Note that not all hardware monitoring drivers do VRM/VRD/VID
    operations, so less drivers depend on hwmon-vid than there were
    depending on i2c-sensor.

    Signed-off-by: Jean Delvare
    Signed-off-by: Greg Kroah-Hartman

    Jean Delvare
     
  • The only thing left in i2c-sensor.h are module parameter definition
    macros. It's only an extension of what i2c.h offers, and this extension
    is not sensors-specific. As a matter of fact, a few non-sensors drivers
    use them. So we better merge them in i2c.h, and get rid of i2c-sensor.h
    altogether.

    Signed-off-by: Jean Delvare
    Signed-off-by: Greg Kroah-Hartman

    Jean Delvare
     
  • i2c_probe and i2c_detect now do the exact same thing and operate on
    the same data structure, so we can have everyone call i2c_probe.

    Signed-off-by: Jean Delvare
    Signed-off-by: Greg Kroah-Hartman

    Jean Delvare
     
  • Fix a typo in the i2c documentation: the i2c bus scanning tool found in
    lm_sensors is called i2cdetect, not i2c_detect.

    Signed-off-by: Jean Delvare
    Signed-off-by: Greg Kroah-Hartman

    Jean Delvare
     
  • We could refactor the error message 34 different i2c drivers print if
    i2c_detach_client() fails in this function itself. Saves quite a few
    lines of code. Documentation is updated to reflect that change.

    Note that this patch should be applied after Rudolf Marek's w83792d
    patches.

    Signed-off-by: Jean Delvare
    Signed-off-by: Greg Kroah-Hartman

    Jean Delvare
     
  • This patch adds documentation entry for W83792D chip.

    Signed-off-by: Rudolf Marek
    Signed-off-by: Greg Kroah-Hartman

    R.Marek@sh.cvut.cz
     
  • Kill all uses of i2c_is_isa_adapter except for the hybrid drivers (it87,
    lm78, w83781d). The i2c-isa adapter not being registered with the i2c
    core anymore, drivers don't have to fear being erroneously attached to
    it.

    Signed-off-by: Greg Kroah-Hartman

    Jean Delvare
     
  • Kill normal_isa in header files, documentation and all chip drivers, as
    it is no more used.

    normal_i2c could be renamed to normal, but I decided not to do so at the
    moment, so as to limit the number of changes. This might be done later
    as part of the i2c_probe/i2c_detect merge.

    Signed-off-by: Greg Kroah-Hartman

    Jean Delvare
     
  • Drop the separate client name for the LM78-J chip. This is really
    only a later revision of the LM78, with almost no difference and
    no difference the driver handles in any case.

    This was the only client name that had a dash in it, and special care
    had to be taken in libsensors because of it. As we plan to write a new
    library soon, I'd like to get rid of this exception before we do.

    As a nice side effect, it saves 876 bytes in lm78.ko.

    Signed-off-by: Jean Delvare
    Signed-off-by: Greg Kroah-Hartman

    Jean Delvare
     
  • Fix a spelling error and change a sysfs name.

    Signed-off-by: Ben Gardner
    Signed-off-by: Greg Kroah-Hartman

    bgardner@wabtec.com
     
  • Updates to the max6875 driver documentation.
    This brings the documentation in sync with the code, which was recently
    simplified.

    This patch is based off 2.6.13-rc2-mm2.

    Signed-off-by: Ben Gardner
    Signed-off-by: Greg Kroah-Hartman

    bgardner@wabtec.com
     

05 Sep, 2005

7 commits

  • Linus Torvalds
     
  • Linus Torvalds
     
  • The attached patch contains a mini howto for using dm-crypt together with
    swsusp.

    Signed-off-by: Andreas Steinmetz
    Signed-off-by: Pavel Machek
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andreas Steinmetz
     
  • Update suspend documentation.

    Signed-off-by: Pavel Machek
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Pavel Machek
     
  • PowerPC 40x and Book-E processors support a watchdog timer at the processor
    core level. The timer has implementation dependent timeout frequencies
    that can be configured by software.

    One the first Watchdog timeout we get a critical exception. It is left to
    board specific code to determine what should happen at this point. If
    nothing is done and another timeout period expires the processor may
    attempt to reset the machine.

    Command line parameters:
    wdt=0 : disable watchdog (default)
    wdt=1 : enable watchdog

    wdt_period=N : N sets the value of the Watchdog Timer Period.

    The Watchdog Timer Period meaning is implementation specific. Check
    User Manual for the processor for more details.

    This patch is based off of work done by Takeharu Kato.

    Signed-off-by: Matt McClintock
    Signed-off-by: Kumar Gala
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kumar Gala
     
  • Add a "smaps" entry to /proc/pid: show howmuch memory is resident in each
    mapping.

    People that want to perform a memory consumption analysing can use it
    mainly if someone needs to figure out which libraries can be reduced for
    embedded systems. So the new features are the physical size of shared and
    clean [or dirty]; private and clean [or dirty].

    Take a look the example below:

    # cat /proc/4576/smaps

    08048000-080dc000 r-xp /bin/bash
    Size: 592 KB
    Rss: 500 KB
    Shared_Clean: 500 KB
    Shared_Dirty: 0 KB
    Private_Clean: 0 KB
    Private_Dirty: 0 KB
    080dc000-080e2000 rw-p /bin/bash
    Size: 24 KB
    Rss: 24 KB
    Shared_Clean: 0 KB
    Shared_Dirty: 0 KB
    Private_Clean: 0 KB
    Private_Dirty: 24 KB
    080e2000-08116000 rw-p
    Size: 208 KB
    Rss: 208 KB
    Shared_Clean: 0 KB
    Shared_Dirty: 0 KB
    Private_Clean: 0 KB
    Private_Dirty: 208 KB
    b7e2b000-b7e34000 r-xp /lib/tls/libnss_files-2.3.2.so
    Size: 36 KB
    Rss: 12 KB
    Shared_Clean: 12 KB
    Shared_Dirty: 0 KB
    Private_Clean: 0 KB
    Private_Dirty: 0 KB
    ...

    (Includes a cleanup from "Richard Purdie" )

    From: Torsten Foertsch

    show_smap calls first show_map and then prints its additional information to
    the seq_file. show_map checks if all it has to print fits into the buffer and
    if yes marks the current vma as written. While that is correct for show_map
    it is not for show_smap. Here the vma should be marked as written only after
    the additional information is also written.

    The attached patch cures the problem. It moves the functionality of the
    show_map function to a new function show_map_internal that is called with an
    additional struct mem_size_stats* argument. Then show_map calls
    show_map_internal with NULL as struct mem_size_stats* whereas show_smap calls
    it with a real pointer. Now the final

    if (m->count < m->size) /* vma is copied successfully */
    m->version = (vma != get_gate_vma(task))? vma->vm_start: 0;

    is done only if the whole entry fits into the buffer.

    Signed-off-by: Hugh Dickins
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Mauricio Lin
     
  • The idea of a swap_device_lock per device, and a swap_list_lock over them all,
    is appealing; but in practice almost every holder of swap_device_lock must
    already hold swap_list_lock, which defeats the purpose of the split.

    The only exceptions have been swap_duplicate, valid_swaphandles and an
    untrodden path in try_to_unuse (plus a few places added in this series).
    valid_swaphandles doesn't show up high in profiles, but swap_duplicate does
    demand attention. However, with the hold time in get_swap_pages so much
    reduced, I've not yet found a load and set of swap device priorities to show
    even swap_duplicate benefitting from the split. Certainly the split is mere
    overhead in the common case of a single swap device.

    So, replace swap_list_lock and swap_device_lock by spinlock_t swap_lock
    (generally we seem to prefer an _ in the name, and not hide in a macro).

    If someone can show a regression in swap_duplicate, then probably we should
    add a hashlock for the swap_map entries alone (shorts being anatomic), so as
    to help the case of the single swap device too.

    Signed-off-by: Hugh Dickins
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Hugh Dickins
     

03 Sep, 2005

1 commit


02 Sep, 2005

3 commits


31 Aug, 2005

3 commits


30 Aug, 2005

4 commits


24 Aug, 2005

1 commit


19 Aug, 2005

1 commit


17 Aug, 2005

1 commit


16 Aug, 2005

2 commits


15 Aug, 2005

1 commit


11 Aug, 2005

1 commit


10 Aug, 2005

1 commit


08 Aug, 2005

1 commit

  • Don't log machine check events left over from boot. Too many BIOSes leave
    bogus events in there.

    This unfortunately also makes it impossible to log events that caused a
    reboot. For people with non broken BIOS there is mce=bootlog

    Signed-off-by: Andi Kleen
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andi Kleen