All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: Heiko J Schick <info@schihei.de>
Cc: linuxppc-dev@ozlabs.org,
	openipmi-developer@lists.sourceforge.net,
	Christian Krafft <krafft@de.ibm.com>
Subject: Re: [Openipmi-developer] [patch 1/1] ipmi: add autosensing of ipmi device on powerpc using device-tree
Date: Mon, 11 Dec 2006 11:11:09 +0100	[thread overview]
Message-ID: <200612111111.10740.arnd@arndb.de> (raw)
In-Reply-To: <89216897-DF66-4C4E-9436-BD7816424139@schihei.de>

On Sunday 10 December 2006 19:42, Heiko J Schick wrote:
> On 09.12.2006, at 12:44, Arnd Bergmann wrote:
> 
> We have to include the IPMI information in a way which can be used  
> for controllers which are accessed via memory mapped or legacy I/O.

There should be no legacy I/O on an of_platform device, but only
on behind a PCI or ISA bus, right? For PCI, the probing happens
using the pci ipmi driver, so that's not our problem here, and
I hope we don't need to worry about ISA buses any more.

> Furthermore, we have to include the register information that it will  
> work not only for KCS interfaces. It should be possible to include BT  
> and SMIC interfaces, too.

yes

> We have two options how we wanna present IPMI in the OFDT.
> 
> (1)
> 
> name = ipmi
> device_type = ipmi
> compatible = ipmi-kcs, ipmi-1.5, ...
> 
> regs = <addr> <len> <addr> <len> (for KCS interfaces)
> 	or
> regs = <addr> <len> <addr> <len> <addr> <len> (for BT and SMIC  
> interfaces)
> 
> (2)
> name = ipmi
> device_type
> regs = <addr> <len>
> reg-spacing = <number>
> reg-size = <number>
> reg-shift = <number>
> 
> The main difference between (1) and (2) is that (2) will represent  
> the whole register region within the reg property. Because of that  
> you have to include additional properties.
> 
> In (1) you will include every register (e.g. Cmd / Status, Data_In /  
> Data_Out, etc.) within the reg property. The values for reg-spacing  
> are calculated by subtracting addr2 - addr1. The reg-size are the  
> len's within the reg property.
> 
> Personally I prefer (1), because I a the moment I don't see a big  
> benefit in (2). For both options of have to implement source code  
> which checks the compatible node to get the used interface type.  
> According to the emitted interface type you have to read in (1) two  
> or three registers from the reg property.
> 
> In (2) you have to calculate two or three addresses (with the help of  
> reg and the additional reg-spacing, etc. properties).

I'd like to see (2), because that's what the driver currently expects.
The common ipmi code in linux _always_ does this calculation anyway, and
(1) only means we have to compute the reg-spacing and reg-size from the
layout of the registers, which gets rather complicated if you have more
than two of them in the reg property.

	Arnd <><

  reply	other threads:[~2006-12-11 10:11 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-12-07 16:22 [patch 0/1] ipmi: add autosensing of ipmi device on powerpc using device-tree Christian Krafft
2006-12-07 16:24 ` [patch 1/1] " Christian Krafft
2006-12-08 10:24   ` Heiko Joerg Schick
2006-12-08 17:19   ` [Openipmi-developer] " Corey Minyard
2006-12-11 12:13     ` Christian Krafft
2006-12-08 18:59   ` Corey Minyard
2006-12-08 19:49     ` Arnd Bergmann
2006-12-08 22:50     ` Benjamin Herrenschmidt
2006-12-09  0:00       ` Arnd Bergmann
2006-12-09  0:07         ` Corey Minyard
2006-12-09 11:44           ` Arnd Bergmann
2006-12-10 18:42             ` Heiko J Schick
2006-12-11 10:11               ` Arnd Bergmann [this message]
2006-12-11 13:01                 ` Heiko J Schick
2006-12-11 13:37                   ` Segher Boessenkool
2006-12-11 13:18               ` Segher Boessenkool
2006-12-11 14:25                 ` Arnd Bergmann
2006-12-11 16:28                   ` Heiko J Schick
2006-12-11 16:58                     ` Segher Boessenkool
2006-12-11 17:20                       ` Christian Krafft
2006-12-11 16:54                   ` Segher Boessenkool
2006-12-09  2:14         ` Benjamin Herrenschmidt
2006-12-09  9:46         ` Segher Boessenkool
2006-12-09 11:46           ` Arnd Bergmann
2006-12-08  0:41 ` [patch 0/1] " Paul Mackerras
2006-12-08 14:04   ` Arnd Bergmann
2006-12-08 17:17     ` [Openipmi-developer] " Corey Minyard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200612111111.10740.arnd@arndb.de \
    --to=arnd@arndb.de \
    --cc=info@schihei.de \
    --cc=krafft@de.ibm.com \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=openipmi-developer@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.