* Location of PCI setup code
@ 2006-06-01 20:46 Thomas Koeller
2006-06-01 23:44 ` Ralf Baechle
0 siblings, 1 reply; 4+ messages in thread
From: Thomas Koeller @ 2006-06-01 20:46 UTC (permalink / raw)
To: linux-mips
Hi,
the PCI setup code for a platform is conventionally located in arch/mips/pci.
I fail to see the benefits of separating this particular part of a platform's
setup from the rest. The PCI setup code will in general contain references to
platform-specific information, such as the overall address space layout, of
which the PCI memory and I/O pages are a part. If the PCI setup code were in
the platform subdirectory, sharing this information by means of a
platform-local header file would be easy. But with the PCI code in
arch/mips/pci, this becomes more difficult. The platform header could be
located somewhere outside the platform's directory, maybe under
'include' (where?), or referenced via an ugly relative path like
'../../vendor/platform/platform.h'. All this seems rather clumsy to me. No
other part of a platform's initialization is separated from the rest in a
similar way, so what is so special about PCI setup that it cannot be in the
platform directory, thereby avoiding all these annoyances?
tk
--
Thomas Koeller, Software Development
Basler Vision Technologies
An der Strusbek 60-62
22926 Ahrensburg
Germany
Tel +49 (4102) 463-390
Fax +49 (4102) 463-46390
mailto:thomas.koeller@baslerweb.com
http://www.baslerweb.com
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Location of PCI setup code
2006-06-01 20:46 Location of PCI setup code Thomas Koeller
@ 2006-06-01 23:44 ` Ralf Baechle
0 siblings, 0 replies; 4+ messages in thread
From: Ralf Baechle @ 2006-06-01 23:44 UTC (permalink / raw)
To: Thomas Koeller; +Cc: linux-mips
On Thu, Jun 01, 2006 at 10:46:17PM +0200, Thomas Koeller wrote:
> the PCI setup code for a platform is conventionally located in arch/mips/pci.
> I fail to see the benefits of separating this particular part of a platform's
> setup from the rest. The PCI setup code will in general contain references to
> platform-specific information, such as the overall address space layout, of
> which the PCI memory and I/O pages are a part. If the PCI setup code were in
> the platform subdirectory, sharing this information by means of a
> platform-local header file would be easy. But with the PCI code in
> arch/mips/pci, this becomes more difficult. The platform header could be
> located somewhere outside the platform's directory, maybe under
> 'include' (where?), or referenced via an ugly relative path like
> '../../vendor/platform/platform.h'. All this seems rather clumsy to me. No
> other part of a platform's initialization is separated from the rest in a
> similar way, so what is so special about PCI setup that it cannot be in the
> platform directory, thereby avoiding all these annoyances?
The per-platform PCI code used to live in the per-platform directories.
It turned into a giant mess, very little code was being shared, it was
hard to uniformly perform any kind of modification or fixes - and more
of that kind of changes will be needed before the PCI codes really
shines.
Ralf
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: Location of PCI setup code
@ 2006-06-02 9:16 ` Koeller, T.
0 siblings, 0 replies; 4+ messages in thread
From: Koeller, T. @ 2006-06-02 9:16 UTC (permalink / raw)
To: linux-mips
> From: Ralf Baechle [mailto:ralf@linux-mips.org]
>
> On Thu, Jun 01, 2006 at 10:46:17PM +0200, Thomas Koeller wrote:
>
> > the PCI setup code for a platform is conventionally located
> in arch/mips/pci.
> > I fail to see the benefits of separating this particular
> part of a platform's
> > setup from the rest. The PCI setup code will in general
> contain references to
> > platform-specific information, such as the overall address
> space layout, of
> > which the PCI memory and I/O pages are a part. If the PCI
> setup code were in
> > the platform subdirectory, sharing this information by means of a
> > platform-local header file would be easy. But with the PCI code in
> > arch/mips/pci, this becomes more difficult. The platform
> header could be
> > located somewhere outside the platform's directory, maybe under
> > 'include' (where?), or referenced via an ugly relative path like
> > '../../vendor/platform/platform.h'. All this seems rather
> clumsy to me. No
> > other part of a platform's initialization is separated from
> the rest in a
> > similar way, so what is so special about PCI setup that it
> cannot be in the
> > platform directory, thereby avoiding all these annoyances?
>
> The per-platform PCI code used to live in the per-platform
> directories.
> It turned into a giant mess, very little code was being shared, it was
> hard to uniformly perform any kind of modification or fixes - and more
> of that kind of changes will be needed before the PCI codes really
> shines.
>
> Ralf
>
So how am I supposed to deal with the issues mentioned?
Should I duplicate the PCI-related platform definitions into
arch/mips/pci? Scattering related information across several places is
generally regarded as poor design, as it will make maintenance more
difficult.
Or should I resort to one of the methods I mentioned, or is there any
other
preferred/recommended way of dealing with this?
tk
-----------------------------------------------
Thomas Koeller, Software Development
Basler Vision Technologies
An der Strusbek 60-62
22926 Ahrensburg
Germany
Tel +49 (4102) 463-390
Fax +49 (4102) 463-46390
mailto:Thomas.Koeller@baslerweb.com
http://www.baslerweb.com
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: Location of PCI setup code
@ 2006-06-02 9:16 ` Koeller, T.
0 siblings, 0 replies; 4+ messages in thread
From: Koeller, T. @ 2006-06-02 9:16 UTC (permalink / raw)
To: linux-mips
> From: Ralf Baechle [mailto:ralf@linux-mips.org]
>
> On Thu, Jun 01, 2006 at 10:46:17PM +0200, Thomas Koeller wrote:
>
> > the PCI setup code for a platform is conventionally located
> in arch/mips/pci.
> > I fail to see the benefits of separating this particular
> part of a platform's
> > setup from the rest. The PCI setup code will in general
> contain references to
> > platform-specific information, such as the overall address
> space layout, of
> > which the PCI memory and I/O pages are a part. If the PCI
> setup code were in
> > the platform subdirectory, sharing this information by means of a
> > platform-local header file would be easy. But with the PCI code in
> > arch/mips/pci, this becomes more difficult. The platform
> header could be
> > located somewhere outside the platform's directory, maybe under
> > 'include' (where?), or referenced via an ugly relative path like
> > '../../vendor/platform/platform.h'. All this seems rather
> clumsy to me. No
> > other part of a platform's initialization is separated from
> the rest in a
> > similar way, so what is so special about PCI setup that it
> cannot be in the
> > platform directory, thereby avoiding all these annoyances?
>
> The per-platform PCI code used to live in the per-platform
> directories.
> It turned into a giant mess, very little code was being shared, it was
> hard to uniformly perform any kind of modification or fixes - and more
> of that kind of changes will be needed before the PCI codes really
> shines.
>
> Ralf
>
So how am I supposed to deal with the issues mentioned?
Should I duplicate the PCI-related platform definitions into
arch/mips/pci? Scattering related information across several places is
generally regarded as poor design, as it will make maintenance more
difficult.
Or should I resort to one of the methods I mentioned, or is there any
other
preferred/recommended way of dealing with this?
tk
-----------------------------------------------
Thomas Koeller, Software Development
Basler Vision Technologies
An der Strusbek 60-62
22926 Ahrensburg
Germany
Tel +49 (4102) 463-390
Fax +49 (4102) 463-46390
mailto:Thomas.Koeller@baslerweb.com
http://www.baslerweb.com
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2006-06-02 9:16 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-06-01 20:46 Location of PCI setup code Thomas Koeller
2006-06-01 23:44 ` Ralf Baechle
-- strict thread matches above, loose matches on Subject: below --
2006-06-02 9:16 Koeller, T.
2006-06-02 9:16 ` Koeller, T.
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.