<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/edac/edac_mc.c, branch linux-3.5.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.5.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.5.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2012-06-11T15:43:16Z</updated>
<entry>
<title>edac: Do alignment logic properly in edac_align_ptr()</title>
<updated>2012-06-11T15:43:16Z</updated>
<author>
<name>Chris Metcalf</name>
</author>
<published>2012-06-06T17:11:05Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8447c4d15e357a458c9051ddc84aa6c8b9c27000'/>
<id>urn:sha1:8447c4d15e357a458c9051ddc84aa6c8b9c27000</id>
<content type='text'>
The logic was checking the sizeof the structure being allocated to
determine whether an alignment fixup was required.  This isn't right;
what we actually care about is the alignment of the actual pointer that's
about to be returned.  This became an issue recently because struct
edac_mc_layer has a size that is not zero modulo eight, so we were
taking the correctly-aligned pointer and forcing it to be misaligned.
On Tile this caused an alignment exception.

Signed-off-by: Chris Metcalf &lt;cmetcalf@tilera.com&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@redhat.com&gt;
</content>
</entry>
<entry>
<title>edac: Initialize the dimm label with the known information</title>
<updated>2012-05-28T22:13:50Z</updated>
<author>
<name>Mauro Carvalho Chehab</name>
</author>
<published>2012-02-09T14:05:20Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5926ff502f6b93ca0c1654f8a5c5317ea236dbdb'/>
<id>urn:sha1:5926ff502f6b93ca0c1654f8a5c5317ea236dbdb</id>
<content type='text'>
While userspace doesn't fill the dimm labels, add there the dimm location,
as described by the used memory model. This could eventually match what
is described at the dmidecode, making easier for people to identify the
memory.

For example, on an Intel motherboard where the DMI table is reliable,
the first memory stick is described as:

Memory Device
	Array Handle: 0x0029
	Error Information Handle: Not Provided
	Total Width: 64 bits
	Data Width: 64 bits
	Size: 2048 MB
	Form Factor: DIMM
	Set: 1
	Locator: A1_DIMM0
	Bank Locator: A1_Node0_Channel0_Dimm0
	Type: &lt;OUT OF SPEC&gt;
	Type Detail: Synchronous
	Speed: 800 MHz
	Manufacturer: A1_Manufacturer0
	Serial Number: A1_SerNum0
	Asset Tag: A1_AssetTagNum0
	Part Number: A1_PartNum0

The memory named as "A1_DIMM0" is physically located at the first
memory controller (node 0), at channel 0, dimm slot 0.

After this patch, the memory label will be filled with:
	/sys/devices/system/edac/mc/csrow0/ch0_dimm_label:mc#0channel#0slot#0

And (after the new EDAC API patches) as:
	/sys/devices/system/edac/mc/mc0/dimm0/dimm_label:mc#0channel#0slot#0

So, even if the memory label is not initialized on userspace, an useful
information with the error location is filled there, expecially since
several systems/motherboards are provided with enough info to map from
channel/slot (or branch/channel/slot) into the DIMM label. So, letting the
EDAC core fill it by default is a good thing.

It should noticed that, as the label filling happens at the
edac_mc_alloc(), drivers can override it to better describe the memories
(and some actually do it).

Cc: Aristeu Rozanski &lt;arozansk@redhat.com&gt;
Cc: Doug Thompson &lt;norsk5@yahoo.com&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@redhat.com&gt;
</content>
</entry>
<entry>
<title>edac: Remove the legacy EDAC ABI</title>
<updated>2012-05-28T22:13:50Z</updated>
<author>
<name>Mauro Carvalho Chehab</name>
</author>
<published>2012-05-02T17:37:00Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=ca0907b9e413bb1d1f3ea123b663535b74928846'/>
<id>urn:sha1:ca0907b9e413bb1d1f3ea123b663535b74928846</id>
<content type='text'>
Now that all drivers got converted to use the new ABI, we can
drop the old one.

Acked-by: Chris Metcalf &lt;cmetcalf@tilera.com&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@redhat.com&gt;
</content>
</entry>
<entry>
<title>edac: Change internal representation to work with layers</title>
<updated>2012-05-28T22:10:59Z</updated>
<author>
<name>Mauro Carvalho Chehab</name>
</author>
<published>2012-04-18T18:20:50Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=4275be63559719c3149b19751029f1b0f1b26775'/>
<id>urn:sha1:4275be63559719c3149b19751029f1b0f1b26775</id>
<content type='text'>
Change the EDAC internal representation to work with non-csrow
based memory controllers.

There are lots of those memory controllers nowadays, and more
are coming. So, the EDAC internal representation needs to be
changed, in order to work with those memory controllers, while
preserving backward compatibility with the old ones.

The edac core was written with the idea that memory controllers
are able to directly access csrows.

This is not true for FB-DIMM and RAMBUS memory controllers.

Also, some recent advanced memory controllers don't present a per-csrows
view. Instead, they view memories as DIMMs, instead of ranks.

So, change the allocation and error report routines to allow
them to work with all types of architectures.

This will allow the removal of several hacks with FB-DIMM and RAMBUS
memory controllers.

Also, several tests were done on different platforms using different
x86 drivers.

TODO: a multi-rank DIMMs are currently represented by multiple DIMM
entries in struct dimm_info. That means that changing a label for one
rank won't change the same label for the other ranks at the same DIMM.
This bug is present since the beginning of the EDAC, so it is not a big
deal. However, on several drivers, it is possible to fix this issue, but
it should be a per-driver fix, as the csrow =&gt; DIMM arrangement may not
be equal for all. So, don't try to fix it here yet.

I tried to make this patch as short as possible, preceding it with
several other patches that simplified the logic here. Yet, as the
internal API changes, all drivers need changes. The changes are
generally bigger in the drivers for FB-DIMMs.

Cc: Aristeu Rozanski &lt;arozansk@redhat.com&gt;
Cc: Doug Thompson &lt;norsk5@yahoo.com&gt;
Cc: Borislav Petkov &lt;borislav.petkov@amd.com&gt;
Cc: Mark Gross &lt;mark.gross@intel.com&gt;
Cc: Jason Uhlenkott &lt;juhlenko@akamai.com&gt;
Cc: Tim Small &lt;tim@buttersideup.com&gt;
Cc: Ranganathan Desikan &lt;ravi@jetztechnologies.com&gt;
Cc: "Arvind R." &lt;arvino55@gmail.com&gt;
Cc: Olof Johansson &lt;olof@lixom.net&gt;
Cc: Egor Martovetsky &lt;egor@pasemi.com&gt;
Cc: Chris Metcalf &lt;cmetcalf@tilera.com&gt;
Cc: Michal Marek &lt;mmarek@suse.cz&gt;
Cc: Jiri Kosina &lt;jkosina@suse.cz&gt;
Cc: Joe Perches &lt;joe@perches.com&gt;
Cc: Dmitry Eremin-Solenikov &lt;dbaryshkov@gmail.com&gt;
Cc: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Cc: Hitoshi Mitake &lt;h.mitake@gmail.com&gt;
Cc: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Cc: "Niklas Söderlund" &lt;niklas.soderlund@ericsson.com&gt;
Cc: Shaohui Xie &lt;Shaohui.Xie@freescale.com&gt;
Cc: Josh Boyer &lt;jwboyer@gmail.com&gt;
Cc: linuxppc-dev@lists.ozlabs.org
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@redhat.com&gt;
</content>
</entry>
<entry>
<title>edac: rewrite edac_align_ptr()</title>
<updated>2012-05-28T22:10:59Z</updated>
<author>
<name>Mauro Carvalho Chehab</name>
</author>
<published>2012-04-16T13:18:12Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=93e4fe64ece4eccf0ff4ac69bceb389290b8ab7c'/>
<id>urn:sha1:93e4fe64ece4eccf0ff4ac69bceb389290b8ab7c</id>
<content type='text'>
The edac_align_ptr() function is used to prepare data for a single
memory allocation kzalloc() call. It counts how many bytes are needed
by some data structure.

Using it as-is is not that trivial, as the quantity of memory elements
reserved is not there, but, instead, it is on a next call.

In order to avoid mistakes when using it, move the number of allocated
elements into it, making easier to use it.

Reviewed-by: Borislav Petkov &lt;bp@amd64.org&gt;
Cc: Aristeu Rozanski &lt;arozansk@redhat.com&gt;
Cc: Doug Thompson &lt;norsk5@yahoo.com&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@redhat.com&gt;
</content>
</entry>
<entry>
<title>edac: move nr_pages to dimm struct</title>
<updated>2012-05-28T22:10:58Z</updated>
<author>
<name>Mauro Carvalho Chehab</name>
</author>
<published>2012-01-28T12:09:38Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a895bf8b1e1ea4c032a8fa8a09475a2ce09fe77a'/>
<id>urn:sha1:a895bf8b1e1ea4c032a8fa8a09475a2ce09fe77a</id>
<content type='text'>
The number of pages is a dimm property. Move it to the dimm struct.

After this change, it is possible to add sysfs nodes for the DIMM's that
will properly represent the DIMM stick properties, including its size.

A TODO fix here is to properly represent dual-rank/quad-rank DIMMs when
the memory controller represents the memory via chip select rows.

Reviewed-by: Aristeu Rozanski &lt;arozansk@redhat.com&gt;
Acked-by: Borislav Petkov &lt;borislav.petkov@amd.com&gt;
Acked-by: Chris Metcalf &lt;cmetcalf@tilera.com&gt;
Cc: Doug Thompson &lt;norsk5@yahoo.com&gt;
Cc: Mark Gross &lt;mark.gross@intel.com&gt;
Cc: Jason Uhlenkott &lt;juhlenko@akamai.com&gt;
Cc: Tim Small &lt;tim@buttersideup.com&gt;
Cc: Ranganathan Desikan &lt;ravi@jetztechnologies.com&gt;
Cc: "Arvind R." &lt;arvino55@gmail.com&gt;
Cc: Olof Johansson &lt;olof@lixom.net&gt;
Cc: Egor Martovetsky &lt;egor@pasemi.com&gt;
Cc: Michal Marek &lt;mmarek@suse.cz&gt;
Cc: Jiri Kosina &lt;jkosina@suse.cz&gt;
Cc: Joe Perches &lt;joe@perches.com&gt;
Cc: Dmitry Eremin-Solenikov &lt;dbaryshkov@gmail.com&gt;
Cc: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Cc: Hitoshi Mitake &lt;h.mitake@gmail.com&gt;
Cc: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Cc: "Niklas Söderlund" &lt;niklas.soderlund@ericsson.com&gt;
Cc: Shaohui Xie &lt;Shaohui.Xie@freescale.com&gt;
Cc: Josh Boyer &lt;jwboyer@gmail.com&gt;
Cc: linuxppc-dev@lists.ozlabs.org
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@redhat.com&gt;
</content>
</entry>
<entry>
<title>edac: move dimm properties to struct dimm_info</title>
<updated>2012-05-28T22:10:58Z</updated>
<author>
<name>Mauro Carvalho Chehab</name>
</author>
<published>2012-01-27T21:38:08Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=084a4fccef39ac7abb039511f32380f28d0b67e6'/>
<id>urn:sha1:084a4fccef39ac7abb039511f32380f28d0b67e6</id>
<content type='text'>
On systems based on chip select rows, all channels need to use memories
with the same properties, otherwise the memories on channels A and B
won't be recognized.

However, such assumption is not true for all types of memory
controllers.

Controllers for FB-DIMM's don't have such requirements.

Also, modern Intel controllers seem to be capable of handling such
differences.

So, we need to get rid of storing the DIMM information into a per-csrow
data, storing it, instead at the right place.

The first step is to move grain, mtype, dtype and edac_mode to the
per-dimm struct.

Reviewed-by: Aristeu Rozanski &lt;arozansk@redhat.com&gt;
Reviewed-by: Borislav Petkov &lt;borislav.petkov@amd.com&gt;
Acked-by: Chris Metcalf &lt;cmetcalf@tilera.com&gt;
Cc: Doug Thompson &lt;norsk5@yahoo.com&gt;
Cc: Borislav Petkov &lt;borislav.petkov@amd.com&gt;
Cc: Mark Gross &lt;mark.gross@intel.com&gt;
Cc: Jason Uhlenkott &lt;juhlenko@akamai.com&gt;
Cc: Tim Small &lt;tim@buttersideup.com&gt;
Cc: Ranganathan Desikan &lt;ravi@jetztechnologies.com&gt;
Cc: "Arvind R." &lt;arvino55@gmail.com&gt;
Cc: Olof Johansson &lt;olof@lixom.net&gt;
Cc: Egor Martovetsky &lt;egor@pasemi.com&gt;
Cc: Michal Marek &lt;mmarek@suse.cz&gt;
Cc: Jiri Kosina &lt;jkosina@suse.cz&gt;
Cc: Joe Perches &lt;joe@perches.com&gt;
Cc: Dmitry Eremin-Solenikov &lt;dbaryshkov@gmail.com&gt;
Cc: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Cc: Hitoshi Mitake &lt;h.mitake@gmail.com&gt;
Cc: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Cc: James Bottomley &lt;James.Bottomley@parallels.com&gt;
Cc: "Niklas Söderlund" &lt;niklas.soderlund@ericsson.com&gt;
Cc: Shaohui Xie &lt;Shaohui.Xie@freescale.com&gt;
Cc: Josh Boyer &lt;jwboyer@gmail.com&gt;
Cc: Mike Williams &lt;mike@mikebwilliams.com&gt;
Cc: linuxppc-dev@lists.ozlabs.org
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@redhat.com&gt;
</content>
</entry>
<entry>
<title>edac: Create a dimm struct and move the labels into it</title>
<updated>2012-05-28T22:10:57Z</updated>
<author>
<name>Mauro Carvalho Chehab</name>
</author>
<published>2012-01-27T17:12:32Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a7d7d2e1a07e3811dc49af2962c940fd8bbb6c8f'/>
<id>urn:sha1:a7d7d2e1a07e3811dc49af2962c940fd8bbb6c8f</id>
<content type='text'>
The way a DIMM is currently represented implies that they're
linked into a per-csrow struct. However, some drivers don't see
csrows, as they're ridden behind some chip like the AMB's
on FBDIMM's, for example.

This forced drivers to fake^Wvirtualize a csrow struct, and to create
a mess under csrow/channel original's concept.

Move the DIMM labels into a per-DIMM struct, and add there
the real location of the socket, in terms of csrow/channel.
Latter patches will modify the location to properly represent the
memory architecture.

All other drivers will use a per-csrow type of location.
Some of those drivers will require a latter conversion, as
they also fake the csrows internally.

TODO: While this patch doesn't change the existing behavior, on
csrows-based memory controllers, a csrow/channel pair points to a memory
rank. There's a known bug at the EDAC core that allows having different
labels for the same DIMM, if it has more than one rank. A latter patch
is need to merge the several ranks for a DIMM into the same dimm_info
struct, in order to avoid having different labels for the same DIMM.

The edac_mc_alloc() will now contain a per-dimm initialization loop that
will be changed by latter patches in order to match other types of
memory architectures.

Reviewed-by: Aristeu Rozanski &lt;arozansk@redhat.com&gt;
Reviewed-by: Borislav Petkov &lt;borislav.petkov@amd.com&gt;
Cc: Doug Thompson &lt;norsk5@yahoo.com&gt;
Cc: Ranganathan Desikan &lt;ravi@jetztechnologies.com&gt;
Cc: "Arvind R." &lt;arvino55@gmail.com&gt;
Cc: "Niklas Söderlund" &lt;niklas.soderlund@ericsson.com&gt;
Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@redhat.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'linux_next' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-edac</title>
<updated>2012-03-28T21:24:40Z</updated>
<author>
<name>Linus Torvalds</name>
</author>
<published>2012-03-28T21:24:40Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=f0f3680e50352c57b6cfc5b0d44d63bb0aa20f80'/>
<id>urn:sha1:f0f3680e50352c57b6cfc5b0d44d63bb0aa20f80</id>
<content type='text'>
Pull EDAC fixes from Mauro Carvalho Chehab:
 "A series of EDAC driver fixes.  It also has one core fix at the
  documentation, and a rename patch, fixing the name of the struct that
  contains the rank information."

* 'linux_next' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-edac:
  edac: rename channel_info to rank_info
  i5400_edac: Avoid calling pci_put_device() twice
  edac: i5100 ack error detection register after each read
  edac: i5100 fix erroneous define for M1Err
  edac: sb_edac: Fix a wrong value setting for the previous value
  edac: sb_edac: Fix a INTERLEAVE_MODE() misuse
  edac: sb_edac: Let the driver depend on PCI_MMCONFIG
  edac: Improve the comments to better describe the memory concepts
  edac/ppc4xx_edac: Fix compilation
  Fix sb_edac compilation with 32 bits kernels
</content>
</entry>
<entry>
<title>edac: rename channel_info to rank_info</title>
<updated>2012-03-21T18:22:50Z</updated>
<author>
<name>Mauro Carvalho Chehab</name>
</author>
<published>2012-01-27T13:26:13Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a4b4be3fd7a76021f67380b03d8bccebf067db72'/>
<id>urn:sha1:a4b4be3fd7a76021f67380b03d8bccebf067db72</id>
<content type='text'>
What it is pointed by a csrow/channel vector is a rank information, and
not a channel information.

On a traditional architecture, the memory controller directly access the
memory ranks, via chip select rows. Different ranks at the same DIMM is
selected via different chip select rows. So, typically, one
csrow/channel pair means one different DIMM.

On FB-DIMMs, there's a microcontroller chip at the DIMM, called Advanced
Memory Buffer (AMB) that serves as the interface between the memory
controller and the memory chips.

The AMB selection is via the DIMM slot, and not via a csrow.

It is up to the AMB to talk with the csrows of the DRAM chips.

So, the FB-DIMM memory controllers see the DIMM slot, and not the DIMM
rank. RAMBUS is similar.

Newer memory controllers, like the ones found on Intel Sandy Bridge and
Nehalem, even working with normal DDR3 DIMM's, don't use the usual
channel A/channel B interleaving schema to provide 128 bits data access.

Instead, they have more channels (3 or 4 channels), and they can use
several interleaving schemas. Such memory controllers see the DIMMs
directly on their registers, instead of the ranks, which is better for
the driver, as its main usageis to point to a broken DIMM stick (the
Field Repleceable Unit), and not to point to a broken DRAM chip.

The drivers that support such such newer memory architecture models
currently need to fake information and to abuse on EDAC structures, as
the subsystem was conceived with the idea that the csrow would always be
visible by the CPU.

To make things a little worse, those drivers don't currently fake
csrows/channels on a consistent way, as the concepts there don't apply
to the memory controllers they're talking with. So, each driver author
interpreted the concepts using a different logic.

In order to fix it, let's rename the data structure that points into a
DIMM rank to "rank_info", in order to be clearer about what's stored
there.

Latter patches will provide a better way to represent the memory
hierarchy for the other types of memory controller.

Signed-off-by: Mauro Carvalho Chehab &lt;mchehab@redhat.com&gt;
</content>
</entry>
</feed>
