mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
serial: core: Make uart_parse_options take const char* argument
The pointed string is never modified from within uart_parse_options, so it should be marked as const in the function prototype. Signed-off-by: Paul Cercueil <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
parent
b9820a3169
commit
0f646b63a1
2 changed files with 4 additions and 3 deletions
|
|
@ -1955,9 +1955,10 @@ EXPORT_SYMBOL_GPL(uart_parse_earlycon);
|
|||
* eg: 115200n8r
|
||||
*/
|
||||
void
|
||||
uart_parse_options(char *options, int *baud, int *parity, int *bits, int *flow)
|
||||
uart_parse_options(const char *options, int *baud, int *parity,
|
||||
int *bits, int *flow)
|
||||
{
|
||||
char *s = options;
|
||||
const char *s = options;
|
||||
|
||||
*baud = simple_strtoul(s, NULL, 10);
|
||||
while (*s >= '0' && *s <= '9')
|
||||
|
|
|
|||
Loading…
Reference in a new issue