Re: [patch] linux 2.4.5: Export mips_machtype

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 23 Aug 2001, Gleb O. Raiko wrote:

> In order to read a PCI ID, you need to know how to do it. In pc world,
> you may rely on configuation access types, at least, ports are known. On
> other arches, you need to know where such "ports" are. Even if hardware
> supports, say, configuration type 1 accesses, developers are free to put
> port addresses anywhere.

 Yep, I see.  MIPS is quite special here, because, unlike for Alphas,
PowerPCs, SPARCs, etc. there is a couple of independend vendors making
systems, so there is no single way of obtaining a system ID.  So you need
to know how to access chipset from elsewhere.

> >  How do you set up mips_machtype on your system in the first place?  At
> > kernel_entry the code does not know what machine it's running on anyway,
> > so it has to set mips_machtype based on a detection algorithm.
> 
> First, mips_machtype is accessed far later than kernel_entry is

 That's quite obvious -- nothing can be done in Linux earlier. ;-)  But
you need to initialize mips_machtype somehow.

> executed. Personally, I am lucky :-), I may read firmware environment
> variables.

 Well, other system might as well (e.g. DECstations can), but that doesn't
solve the problem -- to access firmware variables you need to know which
kind of firmware you are on. 

-- 
+  Maciej W. Rozycki, Technical University of Gdansk, Poland   +
+--------------------------------------------------------------+
+        e-mail: macro@ds2.pg.gda.pl, PGP key available        +



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux