0002-sf-consistently-use-debug-for-warning-error-messages.patch 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. From bb7df8c6ff30be3786483767d3afb0e77a69a640 Mon Sep 17 00:00:00 2001
  2. From: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
  3. Date: Sat, 12 Oct 2013 21:21:18 +0200
  4. Subject: sf: consistently use debug() for warning/error messages
  5. Signed-off-by: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
  6. --- a/drivers/mtd/spi/sf_probe.c
  7. +++ b/drivers/mtd/spi/sf_probe.c
  8. @@ -176,8 +176,8 @@ static struct spi_flash *spi_flash_valid
  9. }
  10. if (i == ARRAY_SIZE(spi_flash_params_table)) {
  11. - printf("SF: Unsupported flash IDs: ");
  12. - printf("manuf %02x, jedec %04x, ext_jedec %04x\n",
  13. + debug("SF: Unsupported flash IDs: ");
  14. + debug("manuf %02x, jedec %04x, ext_jedec %04x\n",
  15. idcode[0], jedec, ext_jedec);
  16. return NULL;
  17. }
  18. @@ -296,7 +296,7 @@ struct spi_flash *spi_flash_probe(unsign
  19. /* Setup spi_slave */
  20. spi = spi_setup_slave(bus, cs, max_hz, spi_mode);
  21. if (!spi) {
  22. - printf("SF: Failed to set up slave\n");
  23. + debug("SF: Failed to set up slave\n");
  24. return NULL;
  25. }
  26. @@ -310,7 +310,7 @@ struct spi_flash *spi_flash_probe(unsign
  27. /* Read the ID codes */
  28. ret = spi_flash_cmd(spi, CMD_READ_ID, idcode, sizeof(idcode));
  29. if (ret) {
  30. - printf("SF: Failed to get idcodes\n");
  31. + debug("SF: Failed to get idcodes\n");
  32. goto err_read_id;
  33. }
  34. @@ -341,8 +341,8 @@ struct spi_flash *spi_flash_probe(unsign
  35. #endif
  36. #ifndef CONFIG_SPI_FLASH_BAR
  37. if (flash->size > SPI_FLASH_16MB_BOUN) {
  38. - puts("SF: Warning - Only lower 16MiB accessible,");
  39. - puts(" Full access #define CONFIG_SPI_FLASH_BAR\n");
  40. + debug("SF: Warning - Only lower 16MiB accessible,");
  41. + debug(" Full access #define CONFIG_SPI_FLASH_BAR\n");
  42. }
  43. #endif