All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3] hw/core/loader.c: Add Extended Tektronix HEX file support
@ 2026-11-12 18:49 Nagendran K
  2026-11-20  0:49 ` Alistair
  2026-11-20 12:05 ` Alex Bennée
  0 siblings, 2 replies; 5+ messages in thread
From: Nagendran K @ 2026-11-12 18:49 UTC (permalink / raw)
  To: qemu-devel
  Cc: berrange, philmd, daan.j.demeyer, peter.maydell, alistair,
	Nagendran K

Add support for loading Extended Tektronix HEX files through the
generic loader.

The loader parses Extended Tektronix records, validates their
checksums, and loads the data at the addresses specified in the file.

This allows Extended Tektronix files to be loaded directly without
manual conversion to another supported format.

Tested by loading an Extended Tektronix file containing a simple UART
application on the RealView EB machine. The application executed
successfully and produced the expected UART output.

Signed-off-by: Nagendran K <nagendranjairam52@gmail.com>
---
 hw/core/loader.c         | 141 +++++++++++++++++++++++----------------
 include/hw/core/loader.h |   7 +-
 2 files changed, 87 insertions(+), 61 deletions(-)

diff --git a/hw/core/loader.c b/hw/core/loader.c
index 2943f69e92..33ccb51d56 100644
--- a/hw/core/loader.c
+++ b/hw/core/loader.c
@@ -1958,8 +1958,11 @@ typedef struct {
 } Ext_Tek_HexLine;
 
 /* return 0 or -1 if error */
-static bool parse_ext_tek_hex_record(Ext_Tek_HexLine *line, uint8_t *our_checksum, const uint8_t c,
-                         uint32_t *index, const bool in_process)
+static bool parse_ext_tek_hex_record(Ext_Tek_HexLine *line,
+                                     uint8_t *our_checksum,
+                                     const uint8_t c,
+                                     uint32_t *index,
+                                     const bool in_process)
 {
     /* +---------+---------------+-----------+---------------+-------------+
      * | record  |    record     |           |               |             |
@@ -1977,27 +1980,35 @@ static bool parse_ext_tek_hex_record(Ext_Tek_HexLine *line, uint8_t *our_checksu
     if (!g_ascii_isxdigit(c) || !in_process) {
         return false;
     }
-    //still idx is computed nibble wise
+    /* still idx is computed nibble wise */
     value = g_ascii_xdigit_value(c);
     value = (idx & 0x1) ? (value & 0xf) : (value << 4);
     if (idx < 2) {
         line->record_length |= value;
-    } else if (idx==2) {
+    } else if (idx == 2) {
         line->record_type |= value;
-    } else if (2 < idx && idx <=4) {
+    } else if (2 < idx && idx <= 4) {
         line->checksum |= value;
     }
-    //Extracting address length from record to fill that many no of address characters in the address field of the line structure. 
-    else if ( idx==5){
+    /*
+     * Extracting address length from record to fill that many no of address
+     * characters in the address field of the line structure.
+     */
+    else if (idx == 5) {
         address_len |= value;
-    }else if (6 <= idx && idx <= (6 + address_len)) {
+    } else if (6 <= idx &&
+                   idx <= (6 + address_len)) {
         line->address <<= address_len;
         line->address += g_ascii_xdigit_value(c);
     }
-    //Checking whether index above address last char index and reaches till record length 
+    /*
+     * Checking whether index above address last char index
+     * and reaches till record length. Right shifting one divides the
+     * nibble wise index by 2 to get the byte wise index to
+     * fill the data field of the line structure
+     */
     else if ((6 + address_len) < idx &&
-               idx <= line->record_length) {
-        //Right shifting one divides the nibble wise index by 2 to get the byte wise index to fill the data field of the line structure.
+              idx <= line->record_length) {
         line->data[(idx - (6 + address_len)) >> 1] |= value;
     } else {
         return false;
@@ -2040,12 +2051,12 @@ static int handle_ext_tek_hex_record_type(Ext_TekHexParser *parser)
         }
 
         /* copy from line buffer to output bin_buf */
-        //sizeof(line->data) is given to dynamically calculate the size of data field
+        /* sizeof(line->data) dynamically calculates the size of data field */
         memcpy(parser->bin_buf + parser->current_rom_index, line->data,
                sizeof(line->data));
         parser->current_rom_index += sizeof(line->data);
         parser->total_size += sizeof(line->data);
-        //As address is absolute address, we dont need to calculate next address to write
+        /* As address is absolute, we dont need to calculate next address */
         break;
 
     case TEK_TERMINATION_RECORD:
@@ -2065,15 +2076,18 @@ static int handle_ext_tek_hex_record_type(Ext_TekHexParser *parser)
 }
 
 /* return size or -1 if error */
-static int parse_ext_tek_hex_blob(const char *filename, hwaddr *addr, uint8_t *ext_tek_blob,
-    size_t ext_tek_blob_size, AddressSpace *as)
-{
-        bool in_process = false; /* avoid re-enter and
-                * check whether record begin with '%' */
+static int parse_ext_tek_hex_blob(const char *filename,
+                                  hwaddr *addr,
+                                  uint8_t *ext_tek_blob,
+                                  size_t ext_tek_blob_size,
+                                  AddressSpace *as)
+{
+    /* avoid re-enter and check whether record begin with '%' */
+        bool in_process = false;
         uint8_t *end = ext_tek_blob + ext_tek_blob_size;
         uint8_t our_checksum = 0;
         uint32_t record_index = 0;
-        
+
         Ext_TekHexParser parser = {
         .filename = filename,
         .bin_buf = g_malloc(ext_tek_blob_size),
@@ -2085,47 +2099,52 @@ static int parse_ext_tek_hex_blob(const char *filename, hwaddr *addr, uint8_t *e
         rom_transaction_begin();
 
         for (; ext_tek_blob < end && !parser.complete; ++ext_tek_blob) {
-        switch (*ext_tek_blob) {
-        case '\r':
-        case '\n':
-        if (!in_process) {
-        break;
-        }
+            switch (*ext_tek_blob) {
+            case '\r':
+            case '\n':
+                if (!in_process) {
+                    break;
+                }
 
-        in_process = false;
-        //record_length byte stores the number of hex characters (nibbles) in the record
-        //so, record_length as the authoritative count of hex characters (nibbles) in the record 
-        //and compare it directly to the nibble index(record index).
-        if ((parser.line.record_length != record_index) || (our_checksum != 0)) {
-        parser.total_size = -1;
-        goto out;
-        }
+                in_process = false;
+                /*
+                 * record_length byte stores the number of hex characters
+                 * (nibbles) in the record and compare it directly to
+                 * the nibble index(record index).
+                 */
+                if ((parser.line.record_length != record_index) ||
+                    (our_checksum != 0)) {
+                    parser.total_size = -1;
+                    goto out;
+                }
 
-        if (handle_ext_tek_hex_record_type(&parser) == -1) {
-        parser.total_size = -1;
-        goto out;
-        }
-        break;
+                if (handle_ext_tek_hex_record_type(&parser) == -1) {
+                    parser.total_size = -1;
+                    goto out;
+                }
+                break;
 
-        /* start of a new record. */
-        case '%':
-        memset(&parser.line, 0, sizeof(Ext_Tek_HexLine));
-        in_process = true;
-        record_index = 0;
-        break;
+            /* start of a new record. */
+            case '%':
+                memset(&parser.line, 0, sizeof(Ext_Tek_HexLine));
+                in_process = true;
+                record_index = 0;
+                break;
 
-        /* decoding lines */
-        default:
-        if (!parse_ext_tek_hex_record(&parser.line, &our_checksum, *ext_tek_blob,
-                &record_index, in_process)) {
-        parser.total_size = -1;
-        goto out;
-        }
-        break;
-        }
+            /* decoding lines */
+            default:
+                if (!parse_ext_tek_hex_record(&parser.line,
+                                            &our_checksum,
+                                            *ext_tek_blob,
+                                            &record_index, in_process)) {
+                    parser.total_size = -1;
+                    goto out;
+                }
+                break;
+            }
         }
 
-        out:
+    out:
         g_free(parser.bin_buf);
         rom_transaction_end(parser.total_size != -1);
         return parser.total_size;
@@ -2133,18 +2152,22 @@ static int parse_ext_tek_hex_blob(const char *filename, hwaddr *addr, uint8_t *e
 
 
 /* return size or -1 if error */
-ssize_t load_targphys_ext_tek_hex_as(const char *filename, hwaddr *entry, AddressSpace *as)
+ssize_t load_targphys_ext_tek_hex_as(const char *filename,
+                                     hwaddr *entry,
+                                     AddressSpace *as)
 {
     gsize ext_tek_blob_size;
     gchar *ext_tek_blob;
     int total_size = 0;
 
-    if (!g_file_get_contents(filename, &ext_tek_blob, &ext_tek_blob_size, NULL)) {
+    if (!g_file_get_contents(filename, &ext_tek_blob,
+                             &ext_tek_blob_size, NULL)) {
         return -1;
     }
-    total_size = parse_ext_tek_hex_blob(filename, entry, (uint8_t *)ext_tek_blob,
-                                ext_tek_blob_size, as);
+    total_size = parse_ext_tek_hex_blob(filename, entry,
+                                       (uint8_t *)ext_tek_blob,
+                                       ext_tek_blob_size, as);
 
     g_free(ext_tek_blob);
     return total_size;
-}
\ No newline at end of file
+}
diff --git a/include/hw/core/loader.h b/include/hw/core/loader.h
index 336a987f85..c0d29b1d44 100644
--- a/include/hw/core/loader.h
+++ b/include/hw/core/loader.h
@@ -57,7 +57,8 @@ ssize_t load_image_targphys_as(const char *filename,
 ssize_t load_targphys_hex_as(const char *filename, hwaddr *entry,
                              AddressSpace *as);
 
-                             /**load_targphys_ext_tek_as:
+/**
+ * load_targphys_ext_tek_as:
  * @filename: Path to the .tek file
  * @entry: Store the entry point given by the .tek file
  * @as: The AddressSpace to load the .tek file to. The value of
@@ -67,7 +68,9 @@ ssize_t load_targphys_hex_as(const char *filename, hwaddr *entry,
  *
  * Returns the size of the loaded .tek file on success, -1 otherwise.
  */
-ssize_t load_targphys_ext_tek_hex_as(const char *filename, hwaddr *entry, AddressSpace *as);
+ssize_t load_targphys_ext_tek_hex_as(const char *filename,
+                                     hwaddr *entry,
+                                     AddressSpace *as);
 
 /** load_image_targphys:
  * Same as load_image_targphys_as(), but doesn't allow the caller to specify
-- 
2.54.0.windows.1



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH v3] hw/core/loader.c: Add Extended Tektronix HEX file support
  2026-11-12 18:49 [PATCH v3] hw/core/loader.c: Add Extended Tektronix HEX file support Nagendran K
@ 2026-11-20  0:49 ` Alistair
  2026-11-20 12:05 ` Alex Bennée
  1 sibling, 0 replies; 5+ messages in thread
From: Alistair @ 2026-11-20  0:49 UTC (permalink / raw)
  To: Nagendran K, qemu-devel; +Cc: berrange, philmd, daan.j.demeyer, peter.maydell

On Fri, 2026-11-13 at 00:19 +0530, Nagendran K wrote:
> Add support for loading Extended Tektronix HEX files through the
> generic loader.
> 
> The loader parses Extended Tektronix records, validates their
> checksums, and loads the data at the addresses specified in the file.
> 
> This allows Extended Tektronix files to be loaded directly without
> manual conversion to another supported format.
> 
> Tested by loading an Extended Tektronix file containing a simple UART
> application on the RealView EB machine. The application executed
> successfully and produced the expected UART output.
> 
> Signed-off-by: Nagendran K <nagendranjairam52@gmail.com>
> ---
>  hw/core/loader.c         | 141 +++++++++++++++++++++++--------------
> --
>  include/hw/core/loader.h |   7 +-
>  2 files changed, 87 insertions(+), 61 deletions(-)
> 
> diff --git a/hw/core/loader.c b/hw/core/loader.c
> index 2943f69e92..33ccb51d56 100644
> --- a/hw/core/loader.c
> +++ b/hw/core/loader.c
> @@ -1958,8 +1958,11 @@ typedef struct {
>  } Ext_Tek_HexLine;
>  
>  /* return 0 or -1 if error */
> -static bool parse_ext_tek_hex_record(Ext_Tek_HexLine *line, uint8_t
> *our_checksum, const uint8_t c,
> -                         uint32_t *index, const bool in_process)

This function does not exist:

https://github.com/qemu/qemu/blob/master/hw/core/loader.c

Alistair

> +static bool parse_ext_tek_hex_record(Ext_Tek_HexLine *line,
> +                                     uint8_t *our_checksum,
> +                                     const uint8_t c,
> +                                     uint32_t *index,
> +                                     const bool in_process)
>  {
>      /* +---------+---------------+-----------+---------------+------
> -------+
>       * | record  |    record     |           |              
> |             |
> @@ -1977,27 +1980,35 @@ static bool
> parse_ext_tek_hex_record(Ext_Tek_HexLine *line, uint8_t *our_checksu
>      if (!g_ascii_isxdigit(c) || !in_process) {
>          return false;
>      }
> -    //still idx is computed nibble wise
> +    /* still idx is computed nibble wise */
>      value = g_ascii_xdigit_value(c);
>      value = (idx & 0x1) ? (value & 0xf) : (value << 4);
>      if (idx < 2) {
>          line->record_length |= value;
> -    } else if (idx==2) {
> +    } else if (idx == 2) {
>          line->record_type |= value;
> -    } else if (2 < idx && idx <=4) {
> +    } else if (2 < idx && idx <= 4) {
>          line->checksum |= value;
>      }
> -    //Extracting address length from record to fill that many no of
> address characters in the address field of the line structure. 
> -    else if ( idx==5){
> +    /*
> +     * Extracting address length from record to fill that many no of
> address
> +     * characters in the address field of the line structure.
> +     */
> +    else if (idx == 5) {
>          address_len |= value;
> -    }else if (6 <= idx && idx <= (6 + address_len)) {
> +    } else if (6 <= idx &&
> +                   idx <= (6 + address_len)) {
>          line->address <<= address_len;
>          line->address += g_ascii_xdigit_value(c);
>      }
> -    //Checking whether index above address last char index and
> reaches till record length 
> +    /*
> +     * Checking whether index above address last char index
> +     * and reaches till record length. Right shifting one divides
> the
> +     * nibble wise index by 2 to get the byte wise index to
> +     * fill the data field of the line structure
> +     */
>      else if ((6 + address_len) < idx &&
> -               idx <= line->record_length) {
> -        //Right shifting one divides the nibble wise index by 2 to
> get the byte wise index to fill the data field of the line structure.
> +              idx <= line->record_length) {
>          line->data[(idx - (6 + address_len)) >> 1] |= value;
>      } else {
>          return false;
> @@ -2040,12 +2051,12 @@ static int
> handle_ext_tek_hex_record_type(Ext_TekHexParser *parser)
>          }
>  
>          /* copy from line buffer to output bin_buf */
> -        //sizeof(line->data) is given to dynamically calculate the
> size of data field
> +        /* sizeof(line->data) dynamically calculates the size of
> data field */
>          memcpy(parser->bin_buf + parser->current_rom_index, line-
> >data,
>                 sizeof(line->data));
>          parser->current_rom_index += sizeof(line->data);
>          parser->total_size += sizeof(line->data);
> -        //As address is absolute address, we dont need to calculate
> next address to write
> +        /* As address is absolute, we dont need to calculate next
> address */
>          break;
>  
>      case TEK_TERMINATION_RECORD:
> @@ -2065,15 +2076,18 @@ static int
> handle_ext_tek_hex_record_type(Ext_TekHexParser *parser)
>  }
>  
>  /* return size or -1 if error */
> -static int parse_ext_tek_hex_blob(const char *filename, hwaddr
> *addr, uint8_t *ext_tek_blob,
> -    size_t ext_tek_blob_size, AddressSpace *as)
> -{
> -        bool in_process = false; /* avoid re-enter and
> -                * check whether record begin with '%' */
> +static int parse_ext_tek_hex_blob(const char *filename,
> +                                  hwaddr *addr,
> +                                  uint8_t *ext_tek_blob,
> +                                  size_t ext_tek_blob_size,
> +                                  AddressSpace *as)
> +{
> +    /* avoid re-enter and check whether record begin with '%' */
> +        bool in_process = false;
>          uint8_t *end = ext_tek_blob + ext_tek_blob_size;
>          uint8_t our_checksum = 0;
>          uint32_t record_index = 0;
> -        
> +
>          Ext_TekHexParser parser = {
>          .filename = filename,
>          .bin_buf = g_malloc(ext_tek_blob_size),
> @@ -2085,47 +2099,52 @@ static int parse_ext_tek_hex_blob(const char
> *filename, hwaddr *addr, uint8_t *e
>          rom_transaction_begin();
>  
>          for (; ext_tek_blob < end && !parser.complete;
> ++ext_tek_blob) {
> -        switch (*ext_tek_blob) {
> -        case '\r':
> -        case '\n':
> -        if (!in_process) {
> -        break;
> -        }
> +            switch (*ext_tek_blob) {
> +            case '\r':
> +            case '\n':
> +                if (!in_process) {
> +                    break;
> +                }
>  
> -        in_process = false;
> -        //record_length byte stores the number of hex characters
> (nibbles) in the record
> -        //so, record_length as the authoritative count of hex
> characters (nibbles) in the record 
> -        //and compare it directly to the nibble index(record index).
> -        if ((parser.line.record_length != record_index) ||
> (our_checksum != 0)) {
> -        parser.total_size = -1;
> -        goto out;
> -        }
> +                in_process = false;
> +                /*
> +                 * record_length byte stores the number of hex
> characters
> +                 * (nibbles) in the record and compare it directly
> to
> +                 * the nibble index(record index).
> +                 */
> +                if ((parser.line.record_length != record_index) ||
> +                    (our_checksum != 0)) {
> +                    parser.total_size = -1;
> +                    goto out;
> +                }
>  
> -        if (handle_ext_tek_hex_record_type(&parser) == -1) {
> -        parser.total_size = -1;
> -        goto out;
> -        }
> -        break;
> +                if (handle_ext_tek_hex_record_type(&parser) == -1) {
> +                    parser.total_size = -1;
> +                    goto out;
> +                }
> +                break;
>  
> -        /* start of a new record. */
> -        case '%':
> -        memset(&parser.line, 0, sizeof(Ext_Tek_HexLine));
> -        in_process = true;
> -        record_index = 0;
> -        break;
> +            /* start of a new record. */
> +            case '%':
> +                memset(&parser.line, 0, sizeof(Ext_Tek_HexLine));
> +                in_process = true;
> +                record_index = 0;
> +                break;
>  
> -        /* decoding lines */
> -        default:
> -        if (!parse_ext_tek_hex_record(&parser.line, &our_checksum,
> *ext_tek_blob,
> -                &record_index, in_process)) {
> -        parser.total_size = -1;
> -        goto out;
> -        }
> -        break;
> -        }
> +            /* decoding lines */
> +            default:
> +                if (!parse_ext_tek_hex_record(&parser.line,
> +                                            &our_checksum,
> +                                            *ext_tek_blob,
> +                                            &record_index,
> in_process)) {
> +                    parser.total_size = -1;
> +                    goto out;
> +                }
> +                break;
> +            }
>          }
>  
> -        out:
> +    out:
>          g_free(parser.bin_buf);
>          rom_transaction_end(parser.total_size != -1);
>          return parser.total_size;
> @@ -2133,18 +2152,22 @@ static int parse_ext_tek_hex_blob(const char
> *filename, hwaddr *addr, uint8_t *e
>  
>  
>  /* return size or -1 if error */
> -ssize_t load_targphys_ext_tek_hex_as(const char *filename, hwaddr
> *entry, AddressSpace *as)
> +ssize_t load_targphys_ext_tek_hex_as(const char *filename,
> +                                     hwaddr *entry,
> +                                     AddressSpace *as)
>  {
>      gsize ext_tek_blob_size;
>      gchar *ext_tek_blob;
>      int total_size = 0;
>  
> -    if (!g_file_get_contents(filename, &ext_tek_blob,
> &ext_tek_blob_size, NULL)) {
> +    if (!g_file_get_contents(filename, &ext_tek_blob,
> +                             &ext_tek_blob_size, NULL)) {
>          return -1;
>      }
> -    total_size = parse_ext_tek_hex_blob(filename, entry, (uint8_t
> *)ext_tek_blob,
> -                                ext_tek_blob_size, as);
> +    total_size = parse_ext_tek_hex_blob(filename, entry,
> +                                       (uint8_t *)ext_tek_blob,
> +                                       ext_tek_blob_size, as);
>  
>      g_free(ext_tek_blob);
>      return total_size;
> -}
> \ No newline at end of file
> +}
> diff --git a/include/hw/core/loader.h b/include/hw/core/loader.h
> index 336a987f85..c0d29b1d44 100644
> --- a/include/hw/core/loader.h
> +++ b/include/hw/core/loader.h
> @@ -57,7 +57,8 @@ ssize_t load_image_targphys_as(const char
> *filename,
>  ssize_t load_targphys_hex_as(const char *filename, hwaddr *entry,
>                               AddressSpace *as);
>  
> -                             /**load_targphys_ext_tek_as:
> +/**
> + * load_targphys_ext_tek_as:
>   * @filename: Path to the .tek file
>   * @entry: Store the entry point given by the .tek file
>   * @as: The AddressSpace to load the .tek file to. The value of
> @@ -67,7 +68,9 @@ ssize_t load_targphys_hex_as(const char *filename,
> hwaddr *entry,
>   *
>   * Returns the size of the loaded .tek file on success, -1
> otherwise.
>   */
> -ssize_t load_targphys_ext_tek_hex_as(const char *filename, hwaddr
> *entry, AddressSpace *as);
> +ssize_t load_targphys_ext_tek_hex_as(const char *filename,
> +                                     hwaddr *entry,
> +                                     AddressSpace *as);
>  
>  /** load_image_targphys:
>   * Same as load_image_targphys_as(), but doesn't allow the caller to
> specify

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v3] hw/core/loader.c: Add Extended Tektronix HEX file support
  2026-11-12 18:49 [PATCH v3] hw/core/loader.c: Add Extended Tektronix HEX file support Nagendran K
  2026-11-20  0:49 ` Alistair
@ 2026-11-20 12:05 ` Alex Bennée
  2026-11-20 14:09   ` Nagendran Jairam
  1 sibling, 1 reply; 5+ messages in thread
From: Alex Bennée @ 2026-11-20 12:05 UTC (permalink / raw)
  To: Nagendran K
  Cc: qemu-devel, berrange, philmd, daan.j.demeyer, peter.maydell,
	alistair

Nagendran K <nagendranjairam52@gmail.com> writes:

> Add support for loading Extended Tektronix HEX files through the
> generic loader.
>
> The loader parses Extended Tektronix records, validates their
> checksums, and loads the data at the addresses specified in the file.
>
> This allows Extended Tektronix files to be loaded directly without
> manual conversion to another supported format.
>
> Tested by loading an Extended Tektronix file containing a simple UART
> application on the RealView EB machine. The application executed
> successfully and produced the expected UART output.
>
> Signed-off-by: Nagendran K <nagendranjairam52@gmail.com>

Ok before you send another version you should consider:

  - split whitespace and comment updates into their own patches
  - include a test case for the loader to show its use
  - verify the whole series applies and builds cleanly on upstream's master branch

And the cover letter for the series should also include what changes
you've made between each iteration. You can also include a summary of
updates under the --- in the commit messages.

-- 
Alex Bennée
Virtualisation Tech Lead @ Linaro


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v3] hw/core/loader.c: Add Extended Tektronix HEX file support
  2026-11-20 12:05 ` Alex Bennée
@ 2026-11-20 14:09   ` Nagendran Jairam
  2026-11-20 15:08     ` Alex Bennée
  0 siblings, 1 reply; 5+ messages in thread
From: Nagendran Jairam @ 2026-11-20 14:09 UTC (permalink / raw)
  To: Alex Bennée
  Cc: qemu-devel, berrange, philmd, daan.j.demeyer, peter.maydell,
	Alistair

[-- Attachment #1: Type: text/plain, Size: 1492 bytes --]

On Fri, Nov 20, 2026, 17:35 Alex Bennée <alex.bennee@linaro.org> wrote:

> Nagendran K <nagendranjairam52@gmail.com> writes:
>
> > Add support for loading Extended Tektronix HEX files through the
> > generic loader.
> >
> > The loader parses Extended Tektronix records, validates their
> > checksums, and loads the data at the addresses specified in the file.
> >
> > This allows Extended Tektronix files to be loaded directly without
> > manual conversion to another supported format.
> >
> > Tested by loading an Extended Tektronix file containing a simple UART
> > application on the RealView EB machine. The application executed
> > successfully and produced the expected UART output.
> >
> > Signed-off-by: Nagendran K <nagendranjairam52@gmail.com>
>
> Ok before you send another version you should consider:
>
>   - split whitespace and comment updates into their own patches
>   - include a test case for the loader to show its use
>   - verify the whole series applies and builds cleanly on upstream's
> master branch
>
> And the cover letter for the series should also include what changes
> you've made between each iteration. You can also include a summary of
> updates under the --- in the commit messages.
>
> --
> Alex Bennée
> Virtualisation Tech Lead @ Linaro
>

   Ok sure, but where do I upload cover letter and testcase means the
baremetal build through which I tested or just overall summary of how did I
test?
     Nagendran

>

[-- Attachment #2: Type: text/html, Size: 2336 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v3] hw/core/loader.c: Add Extended Tektronix HEX file support
  2026-11-20 14:09   ` Nagendran Jairam
@ 2026-11-20 15:08     ` Alex Bennée
  0 siblings, 0 replies; 5+ messages in thread
From: Alex Bennée @ 2026-11-20 15:08 UTC (permalink / raw)
  To: Nagendran Jairam
  Cc: qemu-devel, berrange, philmd, daan.j.demeyer, peter.maydell,
	Alistair

Nagendran Jairam <nagendranjairam52@gmail.com> writes:

> On Fri, Nov 20, 2026, 17:35 Alex Bennée <alex.bennee@linaro.org> wrote:
>
>  Nagendran K <nagendranjairam52@gmail.com> writes:
>
>  > Add support for loading Extended Tektronix HEX files through the
>  > generic loader.
>  >
>  > The loader parses Extended Tektronix records, validates their
>  > checksums, and loads the data at the addresses specified in the file.
>  >
>  > This allows Extended Tektronix files to be loaded directly without
>  > manual conversion to another supported format.
>  >
>  > Tested by loading an Extended Tektronix file containing a simple UART
>  > application on the RealView EB machine. The application executed
>  > successfully and produced the expected UART output.
>  >
>  > Signed-off-by: Nagendran K <nagendranjairam52@gmail.com>
>
>  Ok before you send another version you should consider:
>
>    - split whitespace and comment updates into their own patches
>    - include a test case for the loader to show its use
>    - verify the whole series applies and builds cleanly on upstream's master branch
>
>  And the cover letter for the series should also include what changes
>  you've made between each iteration. You can also include a summary of
>  updates under the --- in the commit messages.
>
>  -- 
>  Alex Bennée
>  Virtualisation Tech Lead @ Linaro
>
>    Ok sure, but where do I upload cover letter and testcase means the baremetal build through which I tested or just overall summary
> of how did I test?

The cover letter is part of a multi-patch series, there is tooling you
can use to help prepare a series:

  https://www.qemu.org/docs/master/devel/submitting-a-patch.html#submitting-your-patches

For the testcase you can either publish a binary asset somewhere and
write a functional test:

  https://www.qemu.org/docs/master/devel/testing/functional.html

Or work out how to build one of the tcg tests and package it up as a hex
file and add a run to test it.

>      Nagendran 

-- 
Alex Bennée
Virtualisation Tech Lead @ Linaro


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-11-20 15:09 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-12 18:49 [PATCH v3] hw/core/loader.c: Add Extended Tektronix HEX file support Nagendran K
2026-11-20  0:49 ` Alistair
2026-11-20 12:05 ` Alex Bennée
2026-11-20 14:09   ` Nagendran Jairam
2026-11-20 15:08     ` Alex Bennée

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.