linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v4 00/21] EEH reorganization
@ 2012-02-24  9:37 Gavin Shan
  2012-02-24  9:37 ` [PATCH 01/21] Cleanup on comments of EEH core Gavin Shan
                   ` (20 more replies)
  0 siblings, 21 replies; 31+ messages in thread
From: Gavin Shan @ 2012-02-24  9:37 UTC (permalink / raw)
  To: linuxppc-dev; +Cc: kernel.crashing.org, shangw

This series of patches is going to reorganize EEH so that it could support
multiple platforms in future. The requirements were raised from the aspects.

	* The original EEH implementation only support pSeries platform, which
	  would be regarded as guest system. Platform powernv is coming and EEH
	  needs to be supported on powernv as well.
	* Different platforms might be running based on variable firmware.Further
	  more, the firmware would supply different EEH interfaces to kernel.
	  Therefore, we have to do necessary abstraction on current EEH implementation.

In order to accomodate the requirements, the series of patches have reorganized
current EEH implementation.

	* The original implementation looks not clean enough. Necessary cleanup
	  will be done in some of the patches.
	* struct eeh_ops has been introduced so that EEH core components and platform
	  dependent implementation could be split up. That make it possible for EEH
	  to be supported on multiple platforms.
	* struct eeh_dev has been introduced to replace struct pci_dn so that EEH module
	  works independently as much as possible.
	* EEH global statistics will be maintained in a collective fashion.

v1 -> v2:

	* If possible, to add "eeh_" prefix for function names.
	* The format of leading function comments won't be changed in order not to
	  break kernel document automatic generation (e.g. by "make pdfdocs").
	* The name of local variables won't be changed if there're no explicit reasons.
	* Represent the PE's state in bitmap fasion.
	* Some function names have been adjusted so that they look shorter and
	  meaningful.
	* Platform operation name has been changed to "pseries".
	* Merge those patches for cleanup if possible.
	* The line length is kept as appropriately short if possible.
	* Fixup on alignment & spacing issues.

v2 -> v3:
	* Split cleanup patch into 2: one for comment cleanup and another one for
	  renaming function names.
	* Try to use pr_warning/pr_info/pr_debug instead of printk() function call.
	* Function names are adjusted a little bit so that they looks more meaningful
	  according to comments from Michael/Ben.
	* Useful comment has been kept according to Michael's comments.
	* struct eeh_ops::set_eeh has been changed to eeh_ops::set_option.
	* struct eeh_ops::name has been changed to "char *".
	* Remove file name from the source file.
	* Copyright (C) format has been changed since "(C)" isn't encouraged to use.
	* The header files included in the source file have been sorted alphabetically.
	* eeh_platform_init() has been replaced by eeh_pseries_init() to avoid duplicate
	  functions when kernel supports multiple platforms.
	* "F/W" has been changed to "Firmware".
	* The maximal wait time to retrieve PE's state has been covered by macro.
	* It also include changes according to the minor comments from Michael.

v3 -> v4:
	* Fix some typo included in the commit messages.
	* Reduce code nesting according to Ram's suggestions.
	* Addtinal pr_warning on failure of configuring bridges.

The series of patches (v4) has been verified on Firebird-L machine. In order to carry out
the test, you have to install IBM Power Tools from IBM internal yum source. Following
command is used to force EEH check on ethernet interface, which could be recovered eventually
by EEH and device driver successfully. You could keep pinging to the blade before issuing
the following command to force EEH. You should see the network interface can't be reached for
a moment and everything will be recovered couple of seconds after the forced EEH error. At the
same time, you should see EEH error log out of system console. 

	* errinjct eeh -v -f 0 -p U78AE.001.WZS00M9-P1-C18-L1-T2 -a 0x0 -m 0x0


-------------

arch/powerpc/include/asm/device.h            |    3 -
arch/powerpc/include/asm/eeh.h               |  143 +---
arch/powerpc/include/asm/eeh_event.h         |   33 +-
arch/powerpc/include/asm/ppc-pci.h           |   89 ++-
arch/powerpc/kernel/of_platform.c            |    3 -
arch/powerpc/kernel/rtas_pci.c               |    3 -
arch/powerpc/platforms/pseries/Makefile      |    3 +-
arch/powerpc/platforms/pseries/eeh.c         | 1016 +++++++++++++++-----------
arch/powerpc/platforms/pseries/eeh_cache.c   |   44 +-
arch/powerpc/platforms/pseries/eeh_driver.c  |  213 +++---
arch/powerpc/platforms/pseries/eeh_event.c   |   55 +-
arch/powerpc/platforms/pseries/eeh_pseries.c |  565 --------------
arch/powerpc/platforms/pseries/eeh_sysfs.c   |   25 +-
arch/powerpc/platforms/pseries/msi.c         |    2 +-
arch/powerpc/platforms/pseries/pci_dlpar.c   |    3 -
arch/powerpc/platforms/pseries/setup.c       |    7 +-
include/linux/of.h                           |    3 -
17 files changed, 861 insertions(+), 1349 deletions(-)

Thanks,
Gavin

^ permalink raw reply	[flat|nested] 31+ messages in thread
* [PATCH v5 00/21] EEH reorganization
@ 2012-02-28  6:03 Gavin Shan
  2012-02-28  6:04 ` [PATCH 16/21] Replace pci_dn with eeh_dev for EEH address cache Gavin Shan
  0 siblings, 1 reply; 31+ messages in thread
From: Gavin Shan @ 2012-02-28  6:03 UTC (permalink / raw)
  To: linuxppc-dev; +Cc: shangw

This series of patches is going to reorganize EEH so that it could support
multiple platforms in future. The requirements were raised from the aspects.

	* The original EEH implementation only support pSeries platform, which
	  would be regarded as guest system. Platform powernv is coming and EEH
	  needs to be supported on powernv as well.
	* Different platforms might be running based on variable firmware.Further
	  more, the firmware would supply different EEH interfaces to kernel.
	  Therefore, we have to do necessary abstraction on current EEH implementation.

In order to accomodate the requirements, the series of patches have reorganized
current EEH implementation.

	* The original implementation looks not clean enough. Necessary cleanup
	  will be done in some of the patches.
	* struct eeh_ops has been introduced so that EEH core components and platform
	  dependent implementation could be split up. That make it possible for EEH
	  to be supported on multiple platforms.
	* struct eeh_dev has been introduced to replace struct pci_dn so that EEH module
	  works independently as much as possible.
	* EEH global statistics will be maintained in a collective fashion.

v1 -> v2:

	* If possible, to add "eeh_" prefix for function names.
	* The format of leading function comments won't be changed in order not to
	  break kernel document automatic generation (e.g. by "make pdfdocs").
	* The name of local variables won't be changed if there're no explicit reasons.
	* Represent the PE's state in bitmap fasion.
	* Some function names have been adjusted so that they look shorter and
	  meaningful.
	* Platform operation name has been changed to "pseries".
	* Merge those patches for cleanup if possible.
	* The line length is kept as appropriately short if possible.
	* Fixup on alignment & spacing issues.

v2 -> v3:
	* Split cleanup patch into 2: one for comment cleanup and another one for
	  renaming function names.
	* Try to use pr_warning/pr_info/pr_debug instead of printk() function call.
	* Function names are adjusted a little bit so that they looks more meaningful
	  according to comments from Michael/Ben.
	* Useful comment has been kept according to Michael's comments.
	* struct eeh_ops::set_eeh has been changed to eeh_ops::set_option.
	* struct eeh_ops::name has been changed to "char *".
	* Remove file name from the source file.
	* Copyright (C) format has been changed since "(C)" isn't encouraged to use.
	* The header files included in the source file have been sorted alphabetically.
	* eeh_platform_init() has been replaced by eeh_pseries_init() to avoid duplicate
	  functions when kernel supports multiple platforms.
	* "F/W" has been changed to "Firmware".
	* The maximal wait time to retrieve PE's state has been covered by macro.
	* It also include changes according to the minor comments from Michael.

v3 -> v4:
	* Fix some typo included in the commit messages.
	* Reduce code nesting according to Ram's suggestions.
	* Addtinal pr_warning on failure of configuring bridges.

v4 -> v5:
	* OF node and PCI device are tracing the corresponding eeh device.
	  That has been changed to "struct eeh_dev *" instead of the original
	  "void *".
	* The conversion between OF node, PCI device, eeh device is changed
	  to inline functions instead of the original macros.
	* The "struct eeh_stats" has been moved from eeh.h to eeh.c. Besides,
	  the individual members of the struct have been changed to fixed-type
	  "unsigned int". 


The series of patches (v5) has been verified on Firebird-L machine. In order to carry out
the test, you have to install IBM Power Tools from IBM internal yum source. Following
command is used to force EEH check on ethernet interface, which could be recovered eventually
by EEH and device driver successfully. You could keep pinging to the blade before issuing
the following command to force EEH. You should see the network interface can't be reached for
a moment and everything will be recovered couple of seconds after the forced EEH error. At the
same time, you should see EEH error log out of system console. 

	* errinjct eeh -v -f 0 -p U78AE.001.WZS00M9-P1-C18-L1-T2 -a 0x0 -m 0x0

-----

arch/powerpc/include/asm/device.h            |    3 +
arch/powerpc/include/asm/eeh.h               |  134 +++-
arch/powerpc/include/asm/eeh_event.h         |   33 +-
arch/powerpc/include/asm/ppc-pci.h           |   89 +--
arch/powerpc/kernel/of_platform.c            |    3 +
arch/powerpc/kernel/rtas_pci.c               |    3 +
arch/powerpc/platforms/pseries/Makefile      |    3 +-
arch/powerpc/platforms/pseries/eeh.c         | 1044 ++++++++++++--------------
arch/powerpc/platforms/pseries/eeh_cache.c   |   44 +-
arch/powerpc/platforms/pseries/eeh_dev.c     |  102 +++
arch/powerpc/platforms/pseries/eeh_driver.c  |  213 +++---
arch/powerpc/platforms/pseries/eeh_event.c   |   55 +-
arch/powerpc/platforms/pseries/eeh_pseries.c |  565 ++++++++++++++
arch/powerpc/platforms/pseries/eeh_sysfs.c   |   25 +-
arch/powerpc/platforms/pseries/msi.c         |    2 +-
arch/powerpc/platforms/pseries/pci_dlpar.c   |    3 +
arch/powerpc/platforms/pseries/setup.c       |    7 +-
include/linux/of.h                           |   10 +
include/linux/pci.h                          |    7 +
19 files changed, 1477 insertions(+), 868 deletions(-)

Thanks,
Gavin

^ permalink raw reply	[flat|nested] 31+ messages in thread

end of thread, other threads:[~2012-02-28  6:04 UTC | newest]

Thread overview: 31+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-24  9:37 [PATCH v4 00/21] EEH reorganization Gavin Shan
2012-02-24  9:37 ` [PATCH 01/21] Cleanup on comments of EEH core Gavin Shan
2012-02-24  9:37 ` [PATCH 02/21] Cleanup on function names " Gavin Shan
2012-02-24  9:38 ` [PATCH 03/21] Platform dependent EEH operations Gavin Shan
2012-02-24  9:38 ` [PATCH 04/21] pSeries platform EEH initialization Gavin Shan
2012-02-24  9:38 ` [PATCH 05/21] pSeries platform EEH operation Gavin Shan
2012-02-24  9:38 ` [PATCH 06/21] pSeries platform EEH PE address retrieval Gavin Shan
2012-02-24  9:38 ` [PATCH 07/21] pSeries platform PE state retrieval Gavin Shan
2012-02-24  9:38 ` [PATCH 08/21] pSeries platform EEH wait PE state Gavin Shan
2012-02-24  9:38 ` [PATCH 09/21] pSeries platform EEH reset PE Gavin Shan
2012-02-24  9:38 ` [PATCH 10/21] pSeries platform EEH error log retrieval Gavin Shan
2012-02-24  9:38 ` [PATCH 11/21] pSeries platform EEH configure bridge Gavin Shan
2012-02-24  9:38 ` [PATCH 12/21] Cleanup on comments of EEH aux components Gavin Shan
2012-02-24  9:38 ` [PATCH 13/21] Cleanup on function names " Gavin Shan
2012-02-24  9:38 ` [PATCH 14/21] Introduce EEH device Gavin Shan
2012-02-24 12:46   ` Stephen Rothwell
2012-02-28  1:13     ` Gavin Shan
2012-02-24 12:50   ` Stephen Rothwell
2012-02-28  1:26     ` Gavin Shan
2012-02-24  9:38 ` [PATCH 15/21] Replace pci_dn with eeh_dev for EEH sysfs Gavin Shan
2012-02-24  9:38 ` [PATCH 16/21] Replace pci_dn with eeh_dev for EEH address cache Gavin Shan
2012-02-24  9:38 ` [PATCH 17/21] Replace pci_dn with eeh_dev for EEH core Gavin Shan
2012-02-24  9:38 ` [PATCH 18/21] Replace pci_dn with eeh_dev for EEH aux components Gavin Shan
2012-02-24  9:38 ` [PATCH 19/21] Replace pci_dn with eeh_dev for EEH on pSeries Gavin Shan
2012-02-24  9:38 ` [PATCH 20/21] Introduce struct eeh_stats for EEH Gavin Shan
2012-02-24 13:01   ` Stephen Rothwell
2012-02-28  1:19     ` Gavin Shan
2012-02-24 13:51   ` David Laight
2012-02-28  1:22     ` Gavin Shan
2012-02-24  9:38 ` [PATCH 21/21] pSeries platform config space access in EEH Gavin Shan
  -- strict thread matches above, loose matches on Subject: below --
2012-02-28  6:03 [PATCH v5 00/21] EEH reorganization Gavin Shan
2012-02-28  6:04 ` [PATCH 16/21] Replace pci_dn with eeh_dev for EEH address cache Gavin Shan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).