Re: [PATCH -mm 2/4] x86_64 boot: Add linked list of structsetup_data

From: Paul Jackson
Date: Thu Mar 27 2008 - 07:25:55 EST


Huang wrote:
+ while (pa_data) {
+ data = early_ioremap(pa_data, PAGE_SIZE);
+ switch (data->type) {
+ default:
+ break;
+ }

Isn't that switch statement equivalent to -always- breaking, as in:

+ while (pa_data) {
+ data = early_ioremap(pa_data, PAGE_SIZE);
+ break;

I doubt you want to do that. I suppose what you want to do is check for
data == NULL instead, as in:

+ while (pa_data) {
+ data = early_ioremap(pa_data, PAGE_SIZE);
+ if (!data)
+ break;

???

--
I won't rest till it's the best ...
Programmer, Linux Scalability
Paul Jackson <pj@xxxxxxx> 1.940.382.4214
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/