Segher Boessenkool wrote:
Really? getprop has only one return value, and it is essential to check it! Well, maybe they always call getproplen before.
Yeah, that's what I see happening during my OpenSolaris boot here. So at the least the CIF client can get the length information it needs.
But it's always an error to have the number of return values (or arguments) not match with what is required.
It doesn't seem too clever. The way I've interpreted the number of returned parameters field in the CIF parameter block is that it's the maximum number of arguments the client would like returned. The original spec isn't clear whether the number of returned items is specified by the caller or set by the BIOS CIF implementation on return. But at least we can correct for it by checking the stack depth. Maybe Tarl has some more insight on this?
ATB,
Mark.