03 Aug, 2010

2 commits

  • Fortify the interface to not accept negative values, remove
    memctrl_int_store() as a result. Also, sanitize bandwidth setting by
    making the argument a simple u32 instead of strange u32 pointer being
    passed around for no obvious reason. Then, fix error handling and teach
    it to return proper error values. Finally, make code more readable,
    simplify debug messages.

    Cc: Mauro Carvalho Chehab
    Cc: Arthur Jones
    Signed-off-by: Borislav Petkov
    Acked-by: Doug Thompson

    Borislav Petkov
     
  • This option differs from EDAC_DEBUG only by printing the file and
    line of where the debug statement is placed, which contains unneeded
    information. So remove it.

    Signed-off-by: Borislav Petkov
    Acked-by: Doug Thompson

    Borislav Petkov
     

10 May, 2010

3 commits


08 Dec, 2009

1 commit

  • Instead of using deeply-nested conditionals for dumping the DIMM type in
    debug mode, add a strings array of the supported DIMM types.

    This is useful in cases where an edac driver supports multiple DRAM
    types and is only defined in debug builds.

    Signed-off-by: Borislav Petkov

    Borislav Petkov
     

21 Sep, 2009

1 commit


01 Jul, 2009

1 commit


19 Jun, 2009

1 commit

  • Add edac_device_alloc_index(), because for MAPLE platform there may
    exist several EDAC driver modules that could make use of
    edac_device_ctl_info structure at the same time. The index allocation
    for these structures should be taken care of by EDAC core.

    [akpm@linux-foundation.org: cleanups]
    Signed-off-by: Harry Ciao
    Cc: Doug Thompson
    Cc: Michael Ellerman
    Cc: Benjamin Herrenschmidt
    Cc: Kumar Gala
    Cc: Paul Mackerras
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Harry Ciao
     

10 Jun, 2009

1 commit


14 Apr, 2009

1 commit

  • Fix the edac local pci_write_bits32 to properly note the 'escape' mask if
    all ones in a 32-bit word.

    Currently no consumer of this function uses that mask, so there is no
    danger to existing code.

    Signed-off-by: Jeff Haran
    Signed-off-by: Doug Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Haran
     

03 Apr, 2009

2 commits

  • Add edac_pci_alloc_index(), because for MAPLE platform there may exist
    several EDAC driver modules that could make use of edac_pci_ctl_info
    structure at the same time. The index allocation for these structures
    should be taken care of by EDAC core.

    Signed-off-by: Harry Ciao
    Cc: Doug Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Harry Ciao
     
  • A patch for making a debugging information more verbose for use in
    development debugging.

    By enabling the new option "More verbose debugging", information about
    source file and line number will be added to debugging message.

    This is sample output,

    EDAC MC0: Giving out device to 'e7xxx_edac' 'E7205': DEV 0000:00:00.0
    EDAC DEBUG: in drivers/edac/edac_pci.c, line at 48: edac_pci_alloc_ctl_info()
    EDAC DEBUG: in drivers/edac/edac_pci.c, line at 334: edac_pci_add_device()
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

    Signed-off-by: Hitoshi Mitake
    Signed-off-by: Doug Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Hitoshi Mitake
     

24 Aug, 2008

1 commit


06 May, 2008

1 commit

  • Commit 06916639e2fed9ee475efef2747a1b7429f8fe76 ("driver-core: add
    dev_name() to help transition away from using bus_id") added a static
    inline dev_name() and used it in dev_printk.

    Unfortunately, drivers/edac/edac_core.h defines a macro called
    dev_name(). Rename the latter.

    Diagnosis by Tony Breeds and Michael Ellerman.

    Signed-off-by: Stephen Rothwell
    Acked-by: Doug Thompson
    Signed-off-by: Linus Torvalds

    Stephen Rothwell
     

08 Feb, 2008

1 commit


20 Oct, 2007

1 commit

  • define global BIT macro

    move all local BIT defines to the new globally define macro.

    Signed-off-by: Jiri Slaby
    Cc: Paul Mackerras
    Cc: Benjamin Herrenschmidt
    Cc: Kumar Gala
    Cc: Dmitry Torokhov
    Cc: Jeff Garzik
    Cc: James Bottomley
    Cc: "Antonino A. Daplas"
    Cc: Russell King
    Acked-by: Ralf Baechle
    Cc: "John W. Linville"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     

12 Sep, 2007

1 commit


20 Jul, 2007

19 commits

  • Some simple fixes to properly reference counter values from the block
    attribute level of edac_device objects. Properly sequencing the array pointer
    was added, resulting in correct identification of block level attributes from
    their base class functions.

    Added more verbose debug statement for event tracking.

    Also during some corner testing, found a bug in the store/show sequence
    of operations for the block attribute/controls management.

    An old intermediate structure for 'blocks' was still in the processing
    pipeline. This patch removes that old structure and correctly utilizes the
    new struct edac_dev_sysfs_block_attribute for passing control from the sysfs
    to the low level store/show function of the edac driver.

    Now the proper kobj pointer to passed downward to the store/show
    functions.

    Signed-off-by: Doug Thompson
    Cc: Greg KH
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Doug Thompson
     
  • With feedback, this patch corrects operation of the kobject release operation
    on kobjects, attributes and controls for the edac_device.

    Cc: Alan Cox alan@lxorguk.ukuu.org.uk
    Signed-off-by: Doug Thompson
    Acked-by: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Douglas Thompson
     
  • This patch refactors the 'releasing' of kobjects for the edac_mc type of
    device. The correct pattern of kobject release is followed.

    As internal kobjs are allocated they bump a ref count on the top level kobj.
    It in turn has a module ref count on the edac_core module. When internal
    kobjects are released, they dec the ref count on the top level kobj. When the
    top level kobj reaches zero, it decrements the ref count on the edac_core
    object, allow it to be unloaded, as all resources have all now been released.

    Cc: Alan Cox alan@lxorguk.ukuu.org.uk
    Signed-off-by: Doug Thompson
    Acked-by: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Doug Thompson
     
  • Refactoring of sysfs code necessitated the refactoring of the
    edac_device_alloc() and edac_device_add_device() apis, of moving the index
    value to the alloc() function. This patch alters the in tree drivers to
    utilize this new api signature.

    Having the index value performed later created a chicken-and-the-egg issue.
    Moving it to the alloc() function allows for creating the necessary sysfs
    entries with the proper index number

    Cc: Alan Cox alan@lxorguk.ukuu.org.uk
    Signed-off-by: Doug Thompson
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Doug Thompson
     
  • Refactoring of sysfs code necessitated the refactoring of the edac_mc_alloc()
    and edac_mc_add_mc() apis, of moving the index value to the alloc() function.
    This patch alters the in tree drivers to utilize this new api signature.

    Having the index value performed later created a chicken-and-the-egg issue.
    Moving it to the alloc() function allows for creating the necessary sysfs
    entries with the proper index number

    Cc: Alan Cox alan@lxorguk.ukuu.org.uk
    Signed-off-by: Doug Thompson
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Doug Thompson
     
  • This patch fixes and enhances the driver level set of sysfs attributes that
    can be added to the 'block' level of an edac_device type of driver.

    There is a controller information structure, which contains one or more
    instances of device. Each instance will have one or more blocks of device
    specific counters. This patch fixes the ability to have more detailed
    attributes/controls for each of the 'blocks', providing for the addition of
    controls/attributes from the low level driver to user space via sysfs.

    Cc: Alan Cox alan@lxorguk.ukuu.org.uk
    Signed-off-by: Douglas Thompson
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Douglas Thompson
     
  • Refactored the function edac_op_state_toString() to be edac_op_state_to_string()
    for consistent style, and its callers

    Signed-off-by: Douglas Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Douglas Thompson
     
  • Refactor the edac_align_ptr() function to reduce the noise of casting the
    aligned pointer to the various types of data objects and modified its callers
    to its new signature

    Signed-off-by: Douglas Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Douglas Thompson
     
  • For the file edac_device.c perform some coding style enhancements
    Add some function header comments
    Made for better readability commands

    Signed-off-by: Douglas Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Douglas Thompson
     
  • Added new controls for the edac_device and edac_mc sysfs folder.
    These can be initialized by the low level driver to provide misc
    controls into the low level driver for its use

    Signed-off-by: Douglas Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Douglas Thompson
     
  • The origin of this code comes from patches at sourceforge, that
    allow EDAC to be updated to various kernels. With kernel version 2.6.20 a
    new workq system was installed, thus the patches needed to be modified
    based on the kernel version. For submitting to the latest kernel.org
    those #ifdefs are removed

    Signed-off-by: Douglas Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Douglas Thompson
     
  • Run the EDAC CORE files through Lindent for cleanup

    Signed-off-by: Douglas Thompson
    Signed-off-by: Dave Jiang
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Douglas Thompson
     
  • Fixup poll values for MC and PCI.
    Also make mc function names unique to mc.

    Signed-off-by: Dave Jiang
    Signed-off-by: Douglas Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Dave Jiang
     
  • Moving PCI to a per-instance device model

    This should include the correct sysfs setup as well. Please review.

    Signed-off-by: Dave Jiang
    Signed-off-by: Douglas Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Dave Jiang
     
  • Move the memory controller object to work queue based implementation from the
    kernel thread based.

    Signed-off-by: Dave Jiang
    Signed-off-by: Douglas Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Dave Jiang
     
  • Move dev_name() macro to a more generic interface since it's not possible
    to determine whether a device is pci, platform, or of_device easily.

    Now each low level driver sets the name into the control structure, and
    the EDAC core references the control structure for the information.

    Better abstraction.

    Signed-off-by: Dave Jiang
    Signed-off-by: Douglas Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Dave Jiang
     
  • Patch to fix some scrubbing #defines in the edac_core.h file

    Signed-off-by: Douglas Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Douglas Thompson
     
  • This patch adds the new 'class' of object to be managed, named: 'edac_device'.

    As a peer of the 'edac_mc' class of object, it provides a non-memory centric
    view of an ERROR DETECTING device in hardware. It provides a sysfs interface
    and an abstraction for varioius EDAC type devices.

    Multiple 'instances' within the class are possible, with each 'instance'
    able to have multiple 'blocks', and each 'block' having 'attributes'.

    At the 'block' level there are the 'ce_count' and 'ue_count' fields
    which the device driver can update and/or call edac_device_handle_XX()
    functions. At each higher level are additional 'total' count fields,
    which are a summation of counts below that level.

    This 'edac_device' has been used to capture and present ECC errors
    which are found in a a L1 and L2 system on a per CORE/CPU basis.

    Signed-off-by: Douglas Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Douglas Thompson
     
  • This is a large patch to refactor the original EDAC module in the kernel
    and to break it up into better file granularity, such that each source
    file contains a given subsystem of the EDAC CORE.

    Originally, the EDAC 'core' was contained in one source file: edac_mc.c
    with it corresponding edac_mc.h file.

    Now, there are the following files:

    edac_module.c The main module init/exit function and other overhead
    edac_mc.c Code handling the edac_mc class of object
    edac_mc_sysfs.c Code handling for sysfs presentation
    edac_pci_sysfs.c Code handling for PCI sysfs presentation
    edac_core.h CORE .h include file for 'edac_mc' and 'edac_device' drivers
    edac_module.h Internal CORE .h include file

    This forms a foundation upon which a later patch can create the 'edac_device'
    class of object code in a new file 'edac_device.c'.

    Signed-off-by: Douglas Thompson
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Douglas Thompson