Commit b4b6a4e4eccb1d2749fd0c3c8a801d333be7e2c1
Committed by
Stefan Roese
1 parent
48e6d34360
Exists in
smarc_8mq_lf_v2020.04
and in
9 other branches
arm: mvebu: turris_omnia: fix checkpatch warnings
Signed-off-by: Marek Behún <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de> Signed-off-by: Stefan Roese <sr@denx.de>
Showing 1 changed file with 8 additions and 8 deletions Side-by-side Diff
board/CZ.NIC/turris_omnia/turris_omnia.c
... | ... | @@ -290,12 +290,12 @@ |
290 | 290 | |
291 | 291 | struct mv_ddr_topology_map *mv_ddr_topology_map_get(void) |
292 | 292 | { |
293 | - static int mem = 0; | |
293 | + static int mem; | |
294 | 294 | struct omnia_eeprom oep; |
295 | 295 | |
296 | 296 | /* Get the board config from EEPROM */ |
297 | - if (mem == 0) { | |
298 | - if(!omnia_read_eeprom(&oep)) | |
297 | + if (!mem) { | |
298 | + if (!omnia_read_eeprom(&oep)) | |
299 | 299 | goto out; |
300 | 300 | |
301 | 301 | printf("Memory config in EEPROM: 0x%02x\n", oep.ramsize); |
... | ... | @@ -368,7 +368,7 @@ |
368 | 368 | |
369 | 369 | int board_init(void) |
370 | 370 | { |
371 | - /* adress of boot parameters */ | |
371 | + /* address of boot parameters */ | |
372 | 372 | gd->bd->bi_boot_params = mvebu_sdram_bar(0) + 0x100; |
373 | 373 | |
374 | 374 | #ifndef CONFIG_SPL_BUILD |
375 | 375 | |
... | ... | @@ -391,9 +391,9 @@ |
391 | 391 | #ifdef CONFIG_ATSHA204A |
392 | 392 | static struct udevice *get_atsha204a_dev(void) |
393 | 393 | { |
394 | - static struct udevice *dev = NULL; | |
394 | + static struct udevice *dev; | |
395 | 395 | |
396 | - if (dev != NULL) | |
396 | + if (dev) | |
397 | 397 | return dev; |
398 | 398 | |
399 | 399 | if (uclass_get_device_by_name(UCLASS_MISC, "atsha204a@64", &dev)) { |
400 | 400 | |
... | ... | @@ -420,13 +420,13 @@ |
420 | 420 | |
421 | 421 | err = atsha204a_read(dev, ATSHA204A_ZONE_OTP, false, |
422 | 422 | OMNIA_ATSHA204_OTP_VERSION, |
423 | - (u8 *) &version_num); | |
423 | + (u8 *)&version_num); | |
424 | 424 | if (err) |
425 | 425 | goto out; |
426 | 426 | |
427 | 427 | err = atsha204a_read(dev, ATSHA204A_ZONE_OTP, false, |
428 | 428 | OMNIA_ATSHA204_OTP_SERIAL, |
429 | - (u8 *) &serial_num); | |
429 | + (u8 *)&serial_num); | |
430 | 430 | if (err) |
431 | 431 | goto out; |
432 | 432 |