CMOS: Add set_option and rework get_option.
[coreboot.git] / src / console / uart8250_console.c
index 37364e710d6a5511fe49799d4034aa0eec78fffb..78921c3059d6c232672c3be433df8bd002c97ac2 100644 (file)
 static void ttyS0_init(void)
 {
        static const unsigned char div[8]={1,2,3,6,12,24,48,96};
-       int b_index=0;
+       unsigned int b_index=0;
        unsigned int divisor=TTYS0_DIV;
 
-       if(get_option(&b_index,"baud_rate")==0) {
+       if(!get_option("baud_rate", &b_index)) {
                divisor=div[b_index];
        }
        uart8250_init(TTYS0_BASE, divisor, TTYS0_LCS);