On Wed, 15 Apr 2009 09:55:08 -0400
David Boyes <[email protected]> wrote:

> On 4/15/09 5:49 AM, "Heiko Carstens" <[email protected]> wrote:
> >
> > How about the patch below?
> > Since I would expect that this is going to happen a lot of times as
> > soon as some distro starts to compile the kernel with e.g. only z9-109
> > and higher support we indeed need a magic number here.
> > Otherwise we can't tell immediately what's going wrong.
>
> Rather than testing for specific model numbers, why don't you test for
> specific capabilities that you need/want? That way you get a exception that
> you can handle and actually issue a useful message or load a specific PSW
> (similar to the way things work on other OSes), rather than just dying in a
> cryptic way.
>
> If I remember, the response from STSI should give you whether a specific set
> of capabilities is present, and then you don't care what weird-ass things
> the marketing people do.

If you look at arch/s390/Makefile you will find this:

cflags-$(CONFIG_MARCH_G5)   += $(call cc-option,-march=g5)
cflags-$(CONFIG_MARCH_Z900) += $(call cc-option,-march=z900)
cflags-$(CONFIG_MARCH_Z990) += $(call cc-option,-march=z990)
cflags-$(CONFIG_MARCH_Z9_109) += $(call cc-option,-march=z9-109)
cflags-$(CONFIG_MARCH_Z10) += $(call cc-option,-march=z10)

We could translate the compile option for a particular model to the
set of capabilities of the machine. That would help with future models
where we don't know the model number yet.

Printing a message is harder to do. We cannot use the device drivers
because they are compiled with options that will generate instruction
that will trap on older machines. The only option would be to use
assembler written function to print a message via sclp.

--
blue skies,
   Martin.

"Reality continues to ruin my life." - Calvin.

----------------------------------------------------------------------
For LINUX-390 subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO LINUX-390 or visit
http://www.marist.edu/htbin/wlvindex?LINUX-390

Reply via email to