mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 11:26:02 +09:00
block/partitions/rk: fix panic when cmdline without mtdparts
Change-Id: I1a3b052ac671ce4abddaf941373f38c11193f0d4 Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
This commit is contained in:
@@ -305,7 +305,10 @@ int rkpart_partition(struct parsed_partitions *state)
|
||||
return 0;
|
||||
|
||||
/* Fixme: parameter should be coherence with part table */
|
||||
cmdline = strstr(saved_command_line, "mtdparts=") + 9;
|
||||
cmdline = strstr(saved_command_line, "mtdparts=");
|
||||
if (!cmdline)
|
||||
return 0;
|
||||
cmdline += 9;
|
||||
cmdline_parsed = 0;
|
||||
|
||||
num_parts = parse_cmdline_partitions(n, &parts, 0);
|
||||
|
||||
Reference in New Issue
Block a user