• Doug Anderson's avatar
    serial: samsung: Use the passed in "port", fixing kgdb w/ no console · bb7f09ba
    Doug Anderson authored
    The two functions in the samsung serial driver used for writing
    characters out to the port were inconsistent about whether they used
    the passed in "port" or the global "cons_uart".  There was no reason
    to use the global and the use of the global in
    s3c24xx_serial_put_poll_char() caused a crash in the case where you
    used the serial port for kgdboc but not for console.
    
    Fix it so we used the passed in variable.
    
    Note that this doesn't fix all problems with the samsung serial
    driver.  Specifically:
    * s3c24xx_serial_console_putchar() is still 99% identical to
      s3c24xx_serial_put_poll_char() (the function signature is different,
      but that's about it).  A future patch will make them slightly less
      identical and judging by other serial drivers we may need yet more
      differences eventually.
    * The samsung serial driver still doesn't allow you to have more than
      one console port since it still uses the global cons_uart in
      s3c24xx_serial_console_write().
    Signed-off-by: default avatarDoug Anderson <dianders@chromium.org>
    Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    bb7f09ba
samsung.c 45.2 KB