[flashrom] [PATCH] Add SUPPORT_EMAIL compiler flag.

David Hendricks dhendrix at google.com
Thu Aug 21 22:20:50 CEST 2014


Overall I like the concept of this patch, and I think it should get merged.

I'm not entirely convinced that redirecting people using the chromiumos
branch to a separate list will significantly reduce the traffic on this
list though. AFAICT most people who report issues are trying to flash
manually with upstream flashrom (or a version bundled with their distro)
and encounter issues with the ME or some such.



On Thu, Aug 21, 2014 at 1:16 AM, Stefan Tauner <
stefan.tauner at alumni.tuwien.ac.at> wrote:

> Use it throughout the source to allow for printing alternative support
> email
> addresses (e.g. for distributions, chromiumos or other 3rd parties).
> Also, fix some indentions on the way.
>
> Signed-off-by: Stefan Tauner <stefan.tauner at alumni.tuwien.ac.at>
> ---
>
> This of course only makes sense if someone uses it (and in the case of
> chromium port it to their tree... and set up some kind of community
> mailing list or something?). Therefore I would like to hear your thoughts
> about it. Would you use it?
>
>  Makefile         |  3 +++
>  bitbang_spi.c    |  2 +-
>  board_enable.c   | 12 ++++++------
>  chipset_enable.c | 16 ++++++----------
>  cli_common.c     |  2 +-
>  dediprog.c       | 10 +++++-----
>  flashrom.c       | 50 +++++++++++++++++++++-----------------------------
>  jedec.c          |  2 +-
>  opaque.c         |  2 +-
>  pcidev.c         | 10 +++++-----
>  physmap.c        |  6 ++----
>  print.c          |  2 +-
>  programmer.c     |  2 +-
>  sb600spi.c       |  8 ++++----
>  sfdp.c           |  5 ++---
>  spi.c            |  6 +++---
>  spi25.c          |  6 +++---
>  17 files changed, 66 insertions(+), 78 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index 98230a5..1e85f41 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -19,6 +19,7 @@
>  #
>
>  PROGRAM = flashrom
> +SUPPORT_EMAIL = flashrom at flashrom.org
>
>
>  ###############################################################################
>  # Defaults for the toolchain.
> @@ -723,6 +724,8 @@ endif
>
>  FEATURE_CFLAGS += $(shell LC_ALL=C grep -q "UTSNAME := yes" .features &&
> printf "%s" "-D'HAVE_UTSNAME=1'")
>
> +FEATURE_CFLAGS += -D'SUPPORT_EMAIL="$(SUPPORT_EMAIL)"'
> +
>  # We could use PULLED_IN_LIBS, but that would be ugly.
>  FEATURE_LIBS += $(shell LC_ALL=C grep -q "NEEDLIBZ := yes" .libdeps &&
> printf "%s" "-lz")
>
> diff --git a/bitbang_spi.c b/bitbang_spi.c
> index 0b27a67..9a0441c 100644
> --- a/bitbang_spi.c
> +++ b/bitbang_spi.c
> @@ -94,7 +94,7 @@ int register_spi_bitbang_master(const struct
> bitbang_spi_master *master)
>             (master->request_bus && !master->release_bus) ||
>             (!master->request_bus && master->release_bus)) {
>                 msg_perr("Incomplete SPI bitbang master setting!\n"
> -                        "Please report a bug at flashrom at flashrom.org
> \n");
> +                        "Please report a bug at " SUPPORT_EMAIL "\n");
>                 return ERROR_FLASHROM_BUG;
>         }
>
> diff --git a/board_enable.c b/board_enable.c
> index 1235bb8..6606a59 100644
> --- a/board_enable.c
> +++ b/board_enable.c
> @@ -335,7 +335,7 @@ void probe_superio_winbond(void)
>                         }
>                         msg_pinfo("Active config mode, unknown reg 0x20
> ID: %02x.\n", model);
>                         msg_pinfo("Please send the output of \"flashrom -V
> -p internal\" to \n"
> -                                 "flashrom at flashrom.org with W836xx:
> your board name: flashrom -V\n"
> +                                 SUPPORT_EMAIL " with W836xx: your board
> name: flashrom -V\n"
>                                   "as the subject to help us finish
> support for your Super I/O. Thanks.\n");
>                         continue;
>                 }
> @@ -620,7 +620,7 @@ int it8705f_write_enable(uint8_t port)
>                         /* The data sheet contradicts itself about max
> size. */
>                         max_rom_decode.parallel = 1024 * 1024;
>                         msg_pinfo("IT8705F with very unusual settings.\n"
> -                                 "Please send the output of \"flashrom -V
> -p internal\" to flashrom at flashrom.org\n"
> +                                 "Please send the output of \"flashrom -V
> -p internal\" to " SUPPORT_EMAIL "\n"
>                                   "with \"IT8705: your board name:
> flashrom -V\" as the subject to help us finish\n"
>                                   "support for your Super I/O. Thanks.\n");
>                         ret = 1;
> @@ -2479,7 +2479,7 @@ int selfcheck_board_enables(void)
>                 const struct board_match *b = &board_matches[i];
>                 if (b->vendor_name == NULL || b->board_name == NULL) {
>                         msg_gerr("ERROR: Board enable #%d does not define
> a vendor and board name.\n"
> -                                "Please report a bug at
> flashrom at flashrom.org\n", i);
> +                                "Please report a bug at " SUPPORT_EMAIL
> "\n", i);
>                         ret = 1;
>                         continue;
>                 }
> @@ -2488,7 +2488,7 @@ int selfcheck_board_enables(void)
>                     ((b->lb_vendor == NULL) ^ (b->lb_part == NULL)) ||
>                     (b->max_rom_decode_parallel == 0 && b->enable ==
> NULL)) {
>                         msg_gerr("ERROR: Board enable for %s %s is
> misdefined.\n"
> -                                "Please report a bug at
> flashrom at flashrom.org\n",
> +                                "Please report a bug at " SUPPORT_EMAIL
> "\n",
>                                  b->vendor_name, b->board_name);
>                         ret = 1;
>                 }
> @@ -2553,7 +2553,7 @@ static const struct board_match
> *board_match_name(const char *vendor, const char
>                 if (partmatch) {
>                         /* More than one entry has a matching name. */
>                         msg_perr("Board name \"%s\":\"%s\" and PCI IDs
> matched more than one board enable "
> -                                "entry. Please report a bug at
> flashrom at flashrom.org\n", vendor, model);
> +                                "entry. Please report a bug at "
> SUPPORT_EMAIL "\n", vendor, model);
>                         return NULL;
>                 }
>                 partmatch = board;
> @@ -2636,7 +2636,7 @@ static int board_enable_safetycheck(const struct
> board_match *board)
>                 return 1;
>         }
>         msg_pwarn("NOTE: Running an untested board enable procedure.\n"
> -                 "Please report success/failure to flashrom at flashrom.org
> .\n");
> +                 "Please report success/failure to " SUPPORT_EMAIL ".\n");
>         return 0;
>  }
>
> diff --git a/chipset_enable.c b/chipset_enable.c
> index dd4e0ea..8334866 100644
> --- a/chipset_enable.c
> +++ b/chipset_enable.c
> @@ -1393,7 +1393,7 @@ static int enable_flash_mcp6x_7x(struct pci_dev
> *dev, const char *name)
>                 internal_buses_supported = BUS_NONE;
>                 msg_pwarn("Flash bus type is unknown (none)\n");
>                 msg_pinfo("Please send the log files created by \"flashrom
> -p internal -o logfile\" to \n"
> -                         "flashrom at flashrom.org with \"your board name:
> flashrom -V\" as the subject to\n"
> +                         SUPPORT_EMAIL " with \"your board name: flashrom
> -V\" as the subject to\n"
>                           "help us finish support for your chipset.
> Thanks.\n");
>                 return ERROR_NONFATAL;
>         }
> @@ -1791,14 +1791,10 @@ int chipset_flash_enable(void)
>                 if (!dev)
>                         continue;
>                 if (ret != -2) {
> -                       msg_pwarn("Warning: unexpected second chipset
> match: "
> -                                   "\"%s %s\"\n"
> -                                 "ignoring, please report lspci and board
> URL "
> -                                   "to flashrom at flashrom.org\n"
> -                                 "with \'CHIPSET: your board name\' in
> the "
> -                                   "subject line.\n",
> -                               chipset_enables[i].vendor_name,
> -                                       chipset_enables[i].device_name);
> +                       msg_pwarn("Warning: unexpected second chipset
> match: \"%s %s\"\n"
> +                                 "ignoring, please report lspci and board
> URL to " SUPPORT_EMAIL "\n"
> +                                 "with \'CHIPSET: your board name\' in
> the subject line.\n",
> +                                 chipset_enables[i].vendor_name,
> chipset_enables[i].device_name);
>                         continue;
>                 }
>                 msg_pinfo("Found chipset \"%s %s\"",
> @@ -1815,7 +1811,7 @@ int chipset_flash_enable(void)
>                                   "flashrom *and* were (not) able to "
>                                   "successfully update your firmware with
> it,\n"
>                                   "then please email a report to "
> -                                 "flashrom at flashrom.org including a
> verbose "
> +                                 SUPPORT_EMAIL " including a verbose "
>                                   "(-V) log.\nThank you!\n");
>                 }
>                 msg_pinfo("Enabling flash write... ");
> diff --git a/cli_common.c b/cli_common.c
> index 71cc2dd..1cae546 100644
> --- a/cli_common.c
> +++ b/cli_common.c
> @@ -107,7 +107,7 @@ void print_chip_support_status(const struct flashchip
> *chip)
>                 }
>                 msg_cinfo("The test status of this chip may have been
> updated in the latest development\n"
>                           "version of flashrom. If you are running the
> latest development version,\n"
> -                         "please email a report to flashrom at flashrom.org
> if any of the above operations\n"
> +                         "please email a report to " SUPPORT_EMAIL " if
> any of the above operations\n"
>                           "work correctly for you with this flash chip.
> Please include the flashrom log\n"
>                           "file for all operations you tested (see the man
> page for details), and mention\n"
>                           "which mainboard or programmer you tested in the
> subject line.\n"
> diff --git a/dediprog.c b/dediprog.c
> index 71a9f8b..676248b 100644
> --- a/dediprog.c
> +++ b/dediprog.c
> @@ -219,8 +219,8 @@ static int dediprog_spi_bulk_read(struct flashctx
> *flash, uint8_t *buf,
>                                         (chunksize >> 8) & 0xff};
>
>         if ((start % chunksize) || (len % chunksize)) {
> -               msg_perr("%s: Unaligned start=%i, len=%i! Please report a
> bug "
> -                        "at flashrom at flashrom.org\n", __func__, start,
> len);
> +               msg_perr("%s: Unaligned start=%i, len=%i! Please report a
> bug at " SUPPORT_EMAIL "\n",
> +                        __func__, start, len);
>                 return 1;
>         }
>
> @@ -326,13 +326,13 @@ static int dediprog_spi_bulk_write(struct flashctx
> *flash, const uint8_t *buf, u
>          */
>         if (chunksize != 256) {
>                 msg_perr("%s: Chunk sizes other than 256 bytes are
> unsupported, chunksize=%u!\n"
> -                        "Please report a bug at flashrom at flashrom.org\n",
> __func__, chunksize);
> +                        "Please report a bug at " SUPPORT_EMAIL "\n",
> __func__, chunksize);
>                 return 1;
>         }
>
>         if ((start % chunksize) || (len % chunksize)) {
> -               msg_perr("%s: Unaligned start=%i, len=%i! Please report a
> bug "
> -                        "at flashrom at flashrom.org\n", __func__, start,
> len);
> +               msg_perr("%s: Unaligned start=%i, len=%i!\nPlease report a
> bug at " SUPPORT_EMAIL "\n",
> +                        __func__, start, len);
>                 return 1;
>         }
>
> diff --git a/flashrom.c b/flashrom.c
> index 93b292b..1148fd4 100644
> --- a/flashrom.c
> +++ b/flashrom.c
> @@ -558,8 +558,7 @@ char *extract_param(const char *const *haystack, const
> char *needle, const char
>
>         needlelen = strlen(needle);
>         if (!needlelen) {
> -               msg_gerr("%s: empty needle! Please report a bug at "
> -                        "flashrom at flashrom.org\n", __func__);
> +               msg_gerr("%s: empty needle! Please report a bug at "
> SUPPORT_EMAIL "\n", __func__);
>                 return NULL;
>         }
>         /* No programmer parameters given. */
> @@ -780,8 +779,7 @@ int need_erase(const uint8_t *have, const uint8_t
> *want, unsigned int len, enum
>                 result = 0;
>                 break;
>         default:
> -               msg_cerr("%s: Unsupported granularity! Please report a bug
> at "
> -                        "flashrom at flashrom.org\n", __func__);
> +               msg_cerr("%s: Unsupported granularity! Please report a bug
> at " SUPPORT_EMAIL "\n", __func__);
>         }
>         return result;
>  }
> @@ -842,8 +840,7 @@ static unsigned int get_next_write(const uint8_t
> *have, const uint8_t *want, uns
>                 stride = 1056;
>                 break;
>         default:
> -               msg_cerr("%s: Unsupported granularity! Please report a bug
> at "
> -                        "flashrom at flashrom.org\n", __func__);
> +               msg_cerr("%s: Unsupported granularity! Please report a bug
> at " SUPPORT_EMAIL "\n", __func__);
>                 /* Claim that no write was needed. A write with unknown
>                  * granularity is too dangerous to try.
>                  */
> @@ -1119,7 +1116,7 @@ int probe_flash(struct registered_master *mst, int
> startchip, struct flashctx *f
>
>                         msg_cinfo(" we need to add them manually.\n"
>                                   "You can help us by mailing us the
> output of the following command to "
> -                                 "flashrom at flashrom.org:\n"
> +                                 SUPPORT_EMAIL ":\n"
>                                   "'flashrom -VV [plus the -p/--programmer
> parameter]'\n"
>                                   "Thanks for your help!\n"
>                                   "===\n");
> @@ -1278,19 +1275,17 @@ static int selfcheck_eraseblocks(const struct
> flashchip *chip)
>                         /* Blocks with zero size are bugs in flashchips.c.
> */
>                         if (eraser.eraseblocks[i].count &&
>                             !eraser.eraseblocks[i].size) {
> -                               msg_gerr("ERROR: Flash chip %s erase
> function "
> -                                       "%i region %i has size 0. Please
> report"
> -                                       " a bug at flashrom at flashrom.org
> \n",
> -                                       chip->name, k, i);
> +                               msg_gerr("ERROR: Flash chip %s erase
> function %i region %i has size 0.\n"
> +                                        "Please report a bug at "
> SUPPORT_EMAIL "\n",
> +                                        chip->name, k, i);
>                                 ret = 1;
>                         }
>                         /* Blocks with zero count are bugs in
> flashchips.c. */
>                         if (!eraser.eraseblocks[i].count &&
>                             eraser.eraseblocks[i].size) {
> -                               msg_gerr("ERROR: Flash chip %s erase
> function "
> -                                       "%i region %i has count 0. Please
> report"
> -                                       " a bug at flashrom at flashrom.org
> \n",
> -                                       chip->name, k, i);
> +                               msg_gerr("ERROR: Flash chip %s erase
> function %i region %i has count 0.\n"
> +                                        "Please report a bug at "
> SUPPORT_EMAIL "\n",
> +                                        chip->name, k, i);
>                                 ret = 1;
>                         }
>                         done += eraser.eraseblocks[i].count *
> @@ -1303,11 +1298,9 @@ static int selfcheck_eraseblocks(const struct
> flashchip *chip)
>                 if (!done)
>                         continue;
>                 if (done != chip->total_size * 1024) {
> -                       msg_gerr("ERROR: Flash chip %s erase function %i "
> -                               "region walking resulted in 0x%06x bytes
> total,"
> -                               " expected 0x%06x bytes. Please report a
> bug at"
> -                               " flashrom at flashrom.org\n", chip->name, k,
> -                               done, chip->total_size * 1024);
> +                       msg_gerr("ERROR: Flash chip %s erase function %i
> region walking resulted in "
> +                                "0x%06x bytes total, expected 0x%06x
> bytes. Please report a bug at"
> +                                SUPPORT_EMAIL "\n", chip->name, k, done,
> chip->total_size * 1024);
>                         ret = 1;
>                 }
>                 if (!eraser.block_erase)
> @@ -1319,10 +1312,9 @@ static int selfcheck_eraseblocks(const struct
> flashchip *chip)
>                 for (j = k + 1; j < NUM_ERASEFUNCTIONS; j++) {
>                         if (eraser.block_erase ==
>                             chip->block_erasers[j].block_erase) {
> -                               msg_gerr("ERROR: Flash chip %s erase
> function "
> -                                       "%i and %i are identical. Please
> report"
> -                                       " a bug at flashrom at flashrom.org
> \n",
> -                                       chip->name, k, j);
> +                               msg_gerr("ERROR: Flash chip %s erase
> function %i and %i are identical.\n"
> +                                        "Please report a bug at "
> SUPPORT_EMAIL "\n",
> +                                        chip->name, k, j);
>                                 ret = 1;
>                         }
>                 }
> @@ -1518,7 +1510,7 @@ static void nonfatal_help_message(void)
>         if (programmer == PROGRAMMER_INTERNAL)
>                 msg_gerr("This means we have to add special support for
> your board, programmer or flash\n"
>                          "chip. Please report this on IRC at
> chat.freenode.net (channel #flashrom) or\n"
> -                        "mail flashrom at flashrom.org, thanks!\n"
> +                        "mail " SUPPORT_EMAIL ", thanks!\n"
>
>  "-------------------------------------------------------------------------------\n"
>                          "You may now reboot or simply leave the machine
> running.\n");
>         else
> @@ -1526,7 +1518,7 @@ static void nonfatal_help_message(void)
>                 msg_gerr("Please check the connections (especially those
> to write protection pins) between\n"
>                          "the programmer and the flash chip. If you think
> the error is caused by flashrom\n"
>                          "please report this on IRC at chat.freenode.net
> (channel #flashrom) or\n"
> -                        "mail flashrom at flashrom.org, thanks!\n");
> +                        "mail " SUPPORT_EMAIL ", thanks!\n");
>  }
>
>  static void emergency_help_message(void)
> @@ -1535,13 +1527,13 @@ static void emergency_help_message(void)
>  #if CONFIG_INTERNAL == 1
>         if (programmer == PROGRAMMER_INTERNAL)
>                 msg_gerr("Get help on IRC at chat.freenode.net (channel
> #flashrom) or\n"
> -                       "mail flashrom at flashrom.org with the subject
> \"FAILED: <your board name>\"!\n"
> +                       "mail " SUPPORT_EMAIL " with the subject \"FAILED:
> <your board name>\"!\n"
>
> "-------------------------------------------------------------------------------\n"
>                         "DO NOT REBOOT OR POWEROFF!\n");
>         else
>  #endif
>                 msg_gerr("Please report this on IRC at chat.freenode.net
> (channel #flashrom) or\n"
> -                        "mail flashrom at flashrom.org, thanks!\n");
> +                        "mail " SUPPORT_EMAIL ", thanks!\n");
>  }
>
>  /* The way to go if you want a delimited list of programmers */
> @@ -1755,7 +1747,7 @@ int selfcheck(void)
>                         if (chip->vendor == NULL || chip->name == NULL ||
> chip->bustype == BUS_NONE) {
>                                 ret = 1;
>                                 msg_gerr("ERROR: Some field of flash chip
> #%d (%s) is misconfigured.\n"
> -                                        "Please report a bug at
> flashrom at flashrom.org\n", i,
> +                                        "Please report a bug at "
> SUPPORT_EMAIL "\n", i,
>                                          chip->name == NULL ? "unnamed" :
> chip->name);
>                         }
>                         if (selfcheck_eraseblocks(chip)) {
> diff --git a/jedec.c b/jedec.c
> index 358b850..fa02c7b 100644
> --- a/jedec.c
> +++ b/jedec.c
> @@ -669,7 +669,7 @@ static int changelock_regspace2_block(const struct
> flashctx *flash, chipaddr off
>
>         if (new_bits & ~REG2_MASK) {
>                 msg_cerr("Invalid locking change 0x%02x requested at
> 0x%0*" PRIxPTR "! "
> -                        "Please report a bug at flashrom at flashrom.org\n",
> +                        "Please report a bug at " SUPPORT_EMAIL "\n",
>                          new_bits, PRIxPTR_WIDTH, offset);
>                 return -1;
>         }
> diff --git a/opaque.c b/opaque.c
> index a5a829c..5bf6737 100644
> --- a/opaque.c
> +++ b/opaque.c
> @@ -56,7 +56,7 @@ int register_opaque_master(const struct opaque_master
> *mst)
>
>         if (!mst->probe || !mst->read || !mst->write || !mst->erase) {
>                 msg_perr("%s called with incomplete master definition. "
> -                        "Please report a bug at flashrom at flashrom.org\n",
> +                        "Please report a bug at " SUPPORT_EMAIL "\n",
>                          __func__);
>                 return ERROR_FLASHROM_BUG;
>         }
> diff --git a/pcidev.c b/pcidev.c
> index 2c78063..6023438 100644
> --- a/pcidev.c
> +++ b/pcidev.c
> @@ -146,7 +146,7 @@ uintptr_t pcidev_readbar(struct pci_dev *dev, int bar)
>                 addr &= PCI_ROM_ADDRESS_MASK;
>                 break;
>         case TYPE_UNKNOWN:
> -               msg_perr("BAR type unknown, please report a bug at
> flashrom at flashrom.org\n");
> +               msg_perr("BAR type unknown, please report a bug at "
> SUPPORT_EMAIL "\n");
>         }
>
>         return (uintptr_t)addr;
> @@ -156,7 +156,7 @@ static int pcidev_shutdown(void *data)
>  {
>         if (pacc == NULL) {
>                 msg_perr("%s: Tried to cleanup an invalid PCI context!\n"
> -                        "Please report a bug at flashrom at flashrom.org\n",
> __func__);
> +                        "Please report a bug at " SUPPORT_EMAIL "\n",
> __func__);
>                 return 1;
>         }
>         pci_cleanup(pacc);
> @@ -167,7 +167,7 @@ int pci_init_common(void)
>  {
>         if (pacc != NULL) {
>                 msg_perr("%s: Tried to allocate a new PCI context, but
> there is still an old one!\n"
> -                        "Please report a bug at flashrom at flashrom.org\n",
> __func__);
> +                        "Please report a bug at " SUPPORT_EMAIL "\n",
> __func__);
>                 return 1;
>         }
>         pacc = pci_alloc();     /* Get the pci_access structure */
> @@ -225,7 +225,7 @@ struct pci_dev *pcidev_init(const struct dev_entry
> *devs, int bar)
>                         if (devs[i].status == NT)
>                                 msg_pinfo("===\nThis PCI device is
> UNTESTED. Please report the 'flashrom -p "
>                                           "xxxx' output \n"
> -                                         "to flashrom at flashrom.org if it
> works for you. Please add the name "
> +                                         "to " SUPPORT_EMAIL " if it
> works for you. Please add the name "
>                                           "of your\n"
>                                           "PCI device to the subject.
> Thank you for your help!\n===\n");
>
> @@ -274,7 +274,7 @@ int undo_pci_write(void *p)
>         struct undo_pci_write_data *data = p;
>         if (pacc == NULL) {
>                 msg_perr("%s: Tried to undo PCI writes without a valid PCI
> context!\n"
> -                        "Please report a bug at flashrom at flashrom.org\n",
> __func__);
> +                        "Please report a bug at " SUPPORT_EMAIL "\n",
> __func__);
>                 return 1;
>         }
>         msg_pdbg("Restoring PCI config space for %02x:%02x:%01x reg
> 0x%02x\n",
> diff --git a/physmap.c b/physmap.c
> index ca5afd0..6fb5e3b 100644
> --- a/physmap.c
> +++ b/physmap.c
> @@ -308,8 +308,7 @@ void physunmap_unaligned(void *virt_addr, size_t len)
>  {
>         /* No need to check for zero size, such mappings would have
> yielded ERROR_PTR. */
>         if (virt_addr == ERROR_PTR) {
> -               msg_perr("Trying to unmap a nonexisting mapping!\n"
> -                        "Please report a bug at flashrom at flashrom.org
> \n");
> +               msg_perr("Trying to unmap a nonexisting mapping!\nPlease
> report a bug at " SUPPORT_EMAIL "\n");
>                 return;
>         }
>
> @@ -322,8 +321,7 @@ void physunmap(void *virt_addr, size_t len)
>
>         /* No need to check for zero size, such mappings would have
> yielded ERROR_PTR. */
>         if (virt_addr == ERROR_PTR) {
> -               msg_perr("Trying to unmap a nonexisting mapping!\n"
> -                        "Please report a bug at flashrom at flashrom.org
> \n");
> +               msg_perr("Trying to unmap a nonexisting mapping!\nPlease
> report a bug at " SUPPORT_EMAIL "\n");
>                 return;
>         }
>         tmp = (uintptr_t)virt_addr;
> diff --git a/print.c b/print.c
> index 243aa49..de9f85f 100644
> --- a/print.c
> +++ b/print.c
> @@ -522,7 +522,7 @@ int print_supported(void)
>                         break;
>                 default:
>                         msg_gerr("\n%s: %s: Uninitialized programmer type!
> Please report a bug at "
> -                                "flashrom at flashrom.org\n", __func__,
> prog.name);
> +                                SUPPORT_EMAIL "\n", __func__, prog.name);
>                         break;
>                 }
>         }
> diff --git a/programmer.c b/programmer.c
> index fd634b2..c88e9b5 100644
> --- a/programmer.c
> +++ b/programmer.c
> @@ -103,7 +103,7 @@ int register_par_master(const struct par_master *mst,
>             !mst->chip_writen || !mst->chip_readb || !mst->chip_readw ||
>             !mst->chip_readl || !mst->chip_readn) {
>                 msg_perr("%s called with incomplete master definition. "
> -                        "Please report a bug at flashrom at flashrom.org\n",
> +                        "Please report a bug at " SUPPORT_EMAIL "\n",
>                          __func__);
>                 return ERROR_FLASHROM_BUG;
>         }
> diff --git a/sb600spi.c b/sb600spi.c
> index 69fad65..381254e 100644
> --- a/sb600spi.c
> +++ b/sb600spi.c
> @@ -106,8 +106,8 @@ static void determine_generation(struct pci_dev *dev)
>                         msg_pdbg("SB8xx/SB9xx/Hudson-1 detected.\n");
>                 } else {
>                         msg_pwarn("SB device found but SMBus revision
> 0x%02x does not match known values.\n"
> -                                 "Assuming SB8xx/SB9xx/Hudson-1. Please
> send a log to flashrom at flashrom.org\n",
> -                                  rev);
> +                                 "Assuming SB8xx/SB9xx/Hudson-1. Please
> send a log to " SUPPORT_EMAIL "\n",
> +                                 rev);
>                         amd_gen = CHIPSET_SB89XX;
>                 }
>         } else if (dev->device_id == 0x780e) {
> @@ -146,13 +146,13 @@ static void determine_generation(struct pci_dev *dev)
>                         msg_pdbg("Yangtze detected.\n");
>                 } else {
>                         msg_pwarn("FCH device found but SMBus revision
> 0x%02x does not match known values.\n"
> -                                 "Please report this to
> flashrom at flashrom.org and include this log and\n"
> +                                 "Please report this to " SUPPORT_EMAIL "
> and include this log and\n"
>                                   "the output of lspci -nnvx, thanks!.\n",
> rev);
>                 }
>  #endif
>         } else
>                 msg_pwarn("%s: Unknown LPC device %" PRIx16 ":%" PRIx16
> ".\n"
> -                         "Please report this to flashrom at flashrom.org
> and include this log and\n"
> +                         "Please report this to " SUPPORT_EMAIL " and
> include this log and\n"
>                           "the output of lspci -nnvx, thanks!\n",
>                           __func__, dev->vendor_id, dev->device_id);
>  }
> diff --git a/sfdp.c b/sfdp.c
> index bc69dd0..ed22392 100644
> --- a/sfdp.c
> +++ b/sfdp.c
> @@ -89,8 +89,7 @@ static int sfdp_add_uniform_eraser(struct flashchip
> *chip, uint8_t opcode, uint3
>
>         if (erasefn == NULL || total_size == 0 || block_size == 0 ||
>             total_size % block_size != 0) {
> -               msg_cdbg("%s: invalid input, please report to "
> -                        "flashrom at flashrom.org\n", __func__);
> +               msg_cdbg("%s: invalid input, please report to "
> SUPPORT_EMAIL "\n", __func__);
>                 return 1;
>         }
>
> @@ -120,7 +119,7 @@ static int sfdp_add_uniform_eraser(struct flashchip
> *chip, uint8_t opcode, uint3
>                 return 0;
>         }
>         msg_cinfo("%s: Not enough space to store another eraser (i=%d)."
> -                 " Please report this at flashrom at flashrom.org\n",
> +                 " Please report this at " SUPPORT_EMAIL "\n",
>                   __func__, i);
>         return 1;
>  }
> diff --git a/spi.c b/spi.c
> index 894f73f..102e9b5 100644
> --- a/spi.c
> +++ b/spi.c
> @@ -82,7 +82,7 @@ int default_spi_read(struct flashctx *flash, uint8_t
> *buf, unsigned int start,
>         if (max_data == MAX_DATA_UNSPECIFIED) {
>                 msg_perr("%s called, but SPI read chunk size not defined "
>                          "on this hardware. Please report a bug at "
> -                        "flashrom at flashrom.org\n", __func__);
> +                        SUPPORT_EMAIL "\n", __func__);
>                 return 1;
>         }
>         return spi_read_chunked(flash, buf, start, len, max_data);
> @@ -94,7 +94,7 @@ int default_spi_write_256(struct flashctx *flash, const
> uint8_t *buf, unsigned i
>         if (max_data == MAX_DATA_UNSPECIFIED) {
>                 msg_perr("%s called, but SPI write chunk size not defined "
>                          "on this hardware. Please report a bug at "
> -                        "flashrom at flashrom.org\n", __func__);
> +                        "" SUPPORT_EMAIL "\n", __func__);
>                 return 1;
>         }
>         return spi_write_chunked(flash, buf, start, len, max_data);
> @@ -174,7 +174,7 @@ int register_spi_master(const struct spi_master *mst)
>             ((mst->command == default_spi_send_command) &&
>              (mst->multicommand == default_spi_send_multicommand))) {
>                 msg_perr("%s called with incomplete master definition. "
> -                        "Please report a bug at flashrom at flashrom.org\n",
> +                        "Please report a bug at " SUPPORT_EMAIL "\n",
>                          __func__);
>                 return ERROR_FLASHROM_BUG;
>         }
> diff --git a/spi25.c b/spi25.c
> index 673bdf5..5cb9632 100644
> --- a/spi25.c
> +++ b/spi25.c
> @@ -835,7 +835,7 @@ erasefunc_t *spi_get_erasefn_from_opcode(uint8_t
> opcode)
>                 return &spi_block_erase_db;
>         default:
>                 msg_cinfo("%s: unknown erase opcode (0x%02x). Please
> report "
> -                         "this at flashrom at flashrom.org\n", __func__,
> opcode);
> +                         "this at " SUPPORT_EMAIL "\n", __func__, opcode);
>                 return NULL;
>         }
>  }
> @@ -1101,7 +1101,7 @@ int default_spi_write_aai(struct flashctx *flash,
> const uint8_t *buf, unsigned i
>         /* The data sheet requires a start address with the low bit
> cleared. */
>         if (start % 2) {
>                 msg_cerr("%s: start address not even! Please report a bug
> at "
> -                        "flashrom at flashrom.org\n", __func__);
> +                        "" SUPPORT_EMAIL "\n", __func__);
>                 if (spi_chip_write_1(flash, buf, start, start % 2))
>                         return SPI_GENERIC_ERROR;
>                 pos += start % 2;
> @@ -1119,7 +1119,7 @@ int default_spi_write_aai(struct flashctx *flash,
> const uint8_t *buf, unsigned i
>         /* The data sheet requires total AAI write length to be even. */
>         if (len % 2) {
>                 msg_cerr("%s: total write length not even! Please report a
> "
> -                        "bug at flashrom at flashrom.org\n", __func__);
> +                        "bug at " SUPPORT_EMAIL "\n", __func__);
>                 /* Do not return an error for now. */
>                 //return SPI_GENERIC_ERROR;
>         }
> --
> Kind regards, Stefan Tauner
>
>


-- 
David Hendricks (dhendrix)
Systems Software Engineer, Google Inc.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.flashrom.org/pipermail/flashrom/attachments/20140821/1e36cdf0/attachment.html>


More information about the flashrom mailing list