14 May, 2016

1 commit

  • Commits 190aa4304de6 (Add AMD Mullins platform support) and
    cca118fa2a0a94 (Add AMD Carrizo platform support) enabled the
    driver on a lot more devices, but the following commit missed
    a single location in the code when checking if the SB800 register
    offsets should be used. This leads to the wrong register being
    written which in turn causes ACPI to go haywire.

    Fix this by introducing a helper function to check for the new
    register layout and use this consistently.

    https://bugzilla.kernel.org/show_bug.cgi?id=114201
    https://bugzilla.redhat.com/show_bug.cgi?id=1329910
    Fixes: bdecfcdb5461 (sp5100_tco: fix the device check for SB800
    and later chipsets)
    Cc: stable@vger.kernel.org (4.5+)
    Signed-off-by: Lucas Stach
    Signed-off-by: Guenter Roeck
    Signed-off-by: Wim Van Sebroeck

    Lucas Stach
     

28 Dec, 2015

3 commits


20 Oct, 2014

1 commit


29 Jan, 2014

1 commit


18 Nov, 2013

1 commit

  • I just can't find any value in MODULE_ALIAS_MISCDEV(WATCHDOG_MINOR)
    and MODULE_ALIAS_MISCDEV(TEMP_MINOR) statements.

    Either the device is enumerated and the driver already has a module
    alias (e.g. PCI, USB etc.) that will get the right driver loaded
    automatically.

    Or the device is not enumerated and loading its driver will lead to
    more or less intrusive hardware poking. Such hardware poking should be
    limited to a bare minimum, so the user should really decide which
    drivers should be tried and in what order. Trying them all in
    arbitrary order can't do any good.

    On top of that, loading that many drivers at once bloats the kernel
    log. Also many drivers will stay loaded afterward, bloating the output
    of "lsmod" and wasting memory. Some modules (cs5535_mfgpt which gets
    loaded as a dependency) can't even be unloaded!

    If defining char-major-10-130 is needed then it should happen in
    user-space.

    Signed-off-by: Jean Delvare
    Acked-by: Guenter Roeck
    Signed-off-by: Wim Van Sebroeck
    Cc: Stephen Warren
    Cc: Mike Frysinger
    Cc: Wan ZongShun
    Cc: Ben Dooks
    Cc: Kukjin Kim
    Cc: Zwane Mwaikambo
    Cc: Jim Cromie

    Jean Delvare
     

23 Mar, 2013

1 commit

  • A problem was found on PC's with the SB700 chipset: The PC fails to
    load BIOS after running the 3.8.x kernel until the power is completely
    cut off. It occurs in all 3.8.x versions and the mainline version as of
    2/4. The issue does not occur with the 3.7.x builds.

    There are two methods for accessing the watchdog registers.

    1. Re-programming a resource address obtained by allocate_resource()
    to chipset.
    2. Use the direct memory-mapped IO access.

    The method 1 can be used by all the chipsets (SP5100, SB7x0, SB8x0 or
    later). However, experience shows that only PC with the SB8x0 (or
    later) chipsets can use the method 2.

    This patch removes the method 1, because the critical problem was found.
    That's why the watchdog timer was able to be used on SP5100 and SB7x0
    chipsets until now.

    Link: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1116835
    Link: https://lkml.org/lkml/2013/2/14/271

    Signed-off-by: Takahisa Tanaka
    Signed-off-by: Wim Van Sebroeck
    Cc: stable

    Takahisa Tanaka
     

01 Mar, 2013

2 commits

  • In case of SP5100 or SB7x0 chipsets, the sp5100_tco module writes zero to
    reserved bits. The module, however, shouldn't depend on specific default
    value, and should perform a read-merge-write operation for the reserved
    bits.

    This patch makes the sp5100_tco module perform a read-merge-write operation
    on all the chipset (sp5100, sb7x0, sb8x0 or later).

    Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=43176
    Signed-off-by: Takahisa Tanaka
    Tested-by: Paul Menzel
    Signed-off-by: Wim Van Sebroeck
    Cc: stable

    Takahisa Tanaka
     
  • In case of SB800 or later chipset and re-programming MMIO address(*),
    sp5100_tco module may read incorrect value of reserved bit, because the module
    reads a value from an incorrect I/O address. However, this bug doesn't cause
    a problem, because when re-programming MMIO address, by chance the module
    writes zero (this is BIOS's default value) to the low three bits of register.
    * In most cases, PC with SB8x0 or later chipset doesn't need to re-programming
    MMIO address, because such PC can enable AcpiMmio and can use 0xfed80b00 for
    watchdog register base address.

    This patch fixes this bug.

    Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=43176
    Signed-off-by: Takahisa Tanaka
    Tested-by: Paul Menzel
    Signed-off-by: Wim Van Sebroeck
    Cc: stable

    Takahisa Tanaka
     

20 Dec, 2012

1 commit

  • The current sp5100_tco driver only supports SP5100/SB7x0 chipset, doesn't
    support SB8x0 chipset, because current sp5100_tco driver doesn't know that the
    offset address for watchdog timer was changed from SB8x0 chipset.

    The offset address of SP5100 and SB7x0 chipsets are as follows, quote from the
    AMD SB700/710/750 Register Reference Guide (Page 164) and the AMD SP5100
    Register Reference Guide (Page 166).

    WatchDogTimerControl 69h
    WatchDogTimerBase0 6Ch
    WatchDogTimerBase1 6Dh
    WatchDogTimerBase2 6Eh
    WatchDogTimerBase3 6Fh

    In contrast, the offset address of SB8x0 chipset is as follows, quote from
    AMD SB800-Series Southbridges Register Reference Guide (Page 147).

    WatchDogTimerEn 48h
    WatchDogTimerConfig 4Ch

    So, In the case of SB8x0 chipset, sp5100_tco reads meaningless MMIO
    address (for example, 0xbafe00) from wrong offset address, and the following
    message is logged.

    SP5100 TCO timer: mmio address 0xbafe00 already in use

    With this patch, sp5100_tco driver supports SB8x0 chipset, and can avoid
    iomem resource conflict. The processing of this patch is as follows.

    Step 1) Attempt to get the watchdog base address from indirect I/O (0xCD6
    and 0xCD7).
    - Go to the step 7 if obtained address hasn't conflicted with other
    resource. But, currently, the address (0xfec000f0) conflicts with the
    IOAPIC MMIO address, and the following message is logged.

    SP5100 TCO timer: mmio address 0xfec000f0 already in use

    0xfec000f0 is recommended by AMD BIOS Developer's Guide. So, go to the
    next step.

    Step 2) Attempt to get the SBResource_MMIO base address from AcpiMmioEN (for
    SB8x0, PM_Reg:24h) or SBResource_MMIO (SP5100/SB7x0, PCI_Reg:9Ch)
    register.
    - Go to the step 7 if these register has enabled by BIOS, and obtained
    address hasn't conflicted with other resource.
    - If above condition isn't true, go to the next step.

    Step 3) Attempt to get the free MMIO address from allocate_resource().
    - Go to the step 7 if these register has enabled by BIOS, and obtained
    address hasn't conflicted with other resource.
    - Driver initialization has failed if obtained address has conflicted
    with other resource, and no 'force_addr' parameter is specified.

    Step 4) Use the specified address If 'force_addr' parameter is specified.
    - allocate_resource() function may fail, when the PCI bridge device occupies
    iomem resource from 0xf0000000 to 0xffffffff. To handle such a case,
    I added 'force_addr' parameter to sp5100_tco driver. With 'force_addr'
    parameter, sp5100_tco driver directly can assign MMIO address for watchdog
    timer from free iomem region. Note that It's dangerous to specify wrong
    address in the 'force_addr' parameter.

    Example of force_addr parameter use
    # cat /proc/iomem
    ...snip...
    fec00000-fec003ff : IOAPIC 0

    Tested-by: Paul Menzel
    Signed-off-by: Takahisa Tanaka
    Signed-off-by: Wim Van Sebroeck

    Takahisa Tanaka
     

29 Nov, 2012

3 commits

  • CONFIG_HOTPLUG is going away as an option so __devexit is no
    longer needed.

    Signed-off-by: Bill Pemberton
    Cc: Wim Van Sebroeck
    Cc: Wan ZongShun
    Cc: Ben Dooks
    Cc: Kukjin Kim
    Acked-by: Mark Brown
    Signed-off-by: Greg Kroah-Hartman

    Bill Pemberton
     
  • CONFIG_HOTPLUG is going away as an option so __devinit is no longer
    needed.

    Signed-off-by: Bill Pemberton
    Cc: Wim Van Sebroeck
    Cc: Wan ZongShun
    Cc: Ben Dooks
    Cc: Kukjin Kim
    Acked-by: Mark Brown
    Signed-off-by: Greg Kroah-Hartman

    Bill Pemberton
     
  • CONFIG_HOTPLUG is going away as an option so __devexit_p is no longer
    needed.

    Signed-off-by: Bill Pemberton
    Cc: Wim Van Sebroeck
    Cc: Wan ZongShun
    Cc: Ben Dooks
    Cc: Kukjin Kim
    Acked-by: Mark Brown
    Signed-off-by: Greg Kroah-Hartman

    Bill Pemberton
     

23 May, 2012

1 commit


28 Mar, 2012

2 commits


29 Mar, 2011

1 commit

  • Stefano found SP5100 TCO watchdog driver using wrong address.

    [ 9.148536] SP5100 TCO timer: SP5100 TCO WatchDog Timer Driver v0.01
    [ 9.148628] DEBUG __ioremap_caller WARNING address=b8fe00 size=8 valid=1 reserved=1

    and e820 said that range is RAM.

    We should check if we can use that reading out. BIOS could just program wrong address there.

    Reported-by: Stefano Stabellini
    Signed-off-by:Yinghai Lu
    Acked-by: Mike Waychison
    Tested-by: Konrad Rzeszutek Wilk
    Signed-off-by: Wim Van Sebroeck
    Cc: stable

    Yinghai Lu
     

16 Mar, 2011

1 commit


12 Jan, 2011

1 commit