Patch Detail
get:
Show a patch.
patch:
Update a patch.
put:
Update a patch.
GET /api/patches/2196075/?format=api
{ "id": 2196075, "url": "http://patchwork.ozlabs.org/api/patches/2196075/?format=api", "web_url": "http://patchwork.ozlabs.org/project/uboot/patch/20260212204511.619392-3-javierm@redhat.com/", "project": { "id": 18, "url": "http://patchwork.ozlabs.org/api/projects/18/?format=api", "name": "U-Boot", "link_name": "uboot", "list_id": "u-boot.lists.denx.de", "list_email": "u-boot@lists.denx.de", "web_url": null, "scm_url": null, "webscm_url": null, "list_archive_url": "", "list_archive_url_format": "", "commit_url_format": "" }, "msgid": "<20260212204511.619392-3-javierm@redhat.com>", "list_archive_url": null, "date": "2026-02-12T20:44:56", "name": "[v2,2/7] disk: part_dos: Align dos_partition_t with struct partition", "commit_ref": null, "pull_url": null, "state": "new", "archived": false, "hash": "a8323ce26e1c260fd3acdde745c946e9c602e2ba", "submitter": { "id": 72132, "url": "http://patchwork.ozlabs.org/api/people/72132/?format=api", "name": "Javier Martinez Canillas", "email": "javierm@redhat.com" }, "delegate": { "id": 68728, "url": "http://patchwork.ozlabs.org/api/users/68728/?format=api", "username": "xypron", "first_name": "Heinrich", "last_name": "Schuchardt", "email": "xypron.glpk@gmx.de" }, "mbox": "http://patchwork.ozlabs.org/project/uboot/patch/20260212204511.619392-3-javierm@redhat.com/mbox/", "series": [ { "id": 492022, "url": "http://patchwork.ozlabs.org/api/series/492022/?format=api", "web_url": "http://patchwork.ozlabs.org/project/uboot/list/?series=492022", "date": "2026-02-12T20:44:54", "name": "efi_loader: disk: Add EFI_PARTITION_INFO_PROTOCOL support for MBR", "version": 2, "mbox": "http://patchwork.ozlabs.org/series/492022/mbox/" } ], "comments": "http://patchwork.ozlabs.org/api/patches/2196075/comments/", "check": "pending", "checks": "http://patchwork.ozlabs.org/api/patches/2196075/checks/", "tags": {}, "related": [], "headers": { "Return-Path": "<u-boot-bounces@lists.denx.de>", "X-Original-To": "incoming@patchwork.ozlabs.org", "Delivered-To": "patchwork-incoming@legolas.ozlabs.org", "Authentication-Results": [ "legolas.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256\n header.s=mimecast20190719 header.b=dYbdqd5S;\n\tdkim-atps=neutral", "legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de\n (client-ip=85.214.62.61; helo=phobos.denx.de;\n envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org)", "phobos.denx.de;\n dmarc=pass (p=quarantine dis=none) header.from=redhat.com", "phobos.denx.de;\n spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de", "phobos.denx.de;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=redhat.com header.i=@redhat.com header.b=\"dYbdqd5S\";\n\tdkim-atps=neutral", "phobos.denx.de; dmarc=pass (p=quarantine dis=none)\n header.from=redhat.com", "phobos.denx.de;\n spf=pass smtp.mailfrom=javierm@redhat.com" ], "Received": [ "from phobos.denx.de (phobos.denx.de [85.214.62.61])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fBnPf2cYPz1xpY\n\tfor <incoming@patchwork.ozlabs.org>; Fri, 13 Feb 2026 07:45:42 +1100 (AEDT)", "from h2850616.stratoserver.net (localhost [IPv6:::1])\n\tby phobos.denx.de (Postfix) with ESMTP id EC7FC83DB6;\n\tThu, 12 Feb 2026 21:45:27 +0100 (CET)", "by phobos.denx.de (Postfix, from userid 109)\n id AD3B983D71; Thu, 12 Feb 2026 21:45:26 +0100 (CET)", "from us-smtp-delivery-124.mimecast.com\n (us-smtp-delivery-124.mimecast.com [170.10.133.124])\n (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))\n (No client certificate requested)\n by phobos.denx.de (Postfix) with ESMTPS id 6B82283A47\n for <u-boot@lists.denx.de>; Thu, 12 Feb 2026 21:45:24 +0100 (CET)", "from mail-wm1-f71.google.com (mail-wm1-f71.google.com\n [209.85.128.71]) by relay.mimecast.com with ESMTP with STARTTLS\n (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id\n us-mta-664-YB2GYX2RP3OXo6t0_Zre2g-1; Thu, 12 Feb 2026 15:45:20 -0500", "by mail-wm1-f71.google.com with SMTP id\n 5b1f17b1804b1-4806cfffca6so2094715e9.2\n for <u-boot@lists.denx.de>; Thu, 12 Feb 2026 12:45:20 -0800 (PST)", "from localhost (62-151-111-63.jazzfree.ya.com. [62.151.111.63])\n by smtp.gmail.com with ESMTPSA id\n 5b1f17b1804b1-48371a298ebsm1026155e9.13.2026.02.12.12.45.17\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Thu, 12 Feb 2026 12:45:17 -0800 (PST)" ], "X-Spam-Checker-Version": "SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de", "X-Spam-Level": "", "X-Spam-Status": "No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH,\n DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,\n RCVD_IN_DNSWL_BLOCKED,RCVD_IN_VALIDITY_CERTIFIED_BLOCKED,\n RCVD_IN_VALIDITY_RPBL_BLOCKED,SPF_HELO_PASS,SPF_PASS autolearn=ham\n autolearn_force=no version=3.4.2", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n s=mimecast20190719; t=1770929122;\n h=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n to:to:cc:cc:mime-version:mime-version:content-type:content-type:\n content-transfer-encoding:content-transfer-encoding:\n in-reply-to:in-reply-to:references:references;\n bh=+JHhKRwKgjcBzLn3rJkmebNMGs1jkBQEwco60cqbAIo=;\n b=dYbdqd5SVUmMU3A5E7zG1qsLhXdL0egjfI2F2hN01Az7hW6JxGHzwCg66yoFReabrcxIAA\n IOhNGVcI6+rGlxhDgmizAgb+soqz3+hbF9tJ+XVJ0kb4cjoPoMZ6560z68Z5WYn9LeYrcU\n +YuwGcPbIJXOkiI4OWeI45a9bWV/GRM=", "X-MC-Unique": "YB2GYX2RP3OXo6t0_Zre2g-1", "X-Mimecast-MFC-AGG-ID": "YB2GYX2RP3OXo6t0_Zre2g_1770929120", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20230601; t=1770929119; x=1771533919;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n :to:cc:subject:date:message-id:reply-to;\n bh=+JHhKRwKgjcBzLn3rJkmebNMGs1jkBQEwco60cqbAIo=;\n b=PHJ6nl+VJBgi4wdUK5jajmvkVU6nK63cxFvYbfY7wOEVXaAkfO19aM+8y1TFF8N0Wk\n WXbVzz82QFSrokme964OkS9dzPHeZmPP+VI6NJ4LLectMM4A/Kr+Uq0YsO2jzJ5cEk+o\n OouPIUMK+oo3P3KrVz+gNJFMUMxdyiMuJg27OVVbecxc4t+q7ZsoxQBSisj6w7xCZYwZ\n pS6NDeGtn9hRSJFxy6I0GQZLtGsUV1FfjBx7Bg1+aZX0yFJYMW9mBYrDZObDmOyk/XrJ\n GirozlvQyuOKoBS34p0gXxiikK+6WgryWdgGHc8Nxuec5EpT9A2Gxk4gYpkC1Tk+1iHJ\n juOQ==", "X-Gm-Message-State": "AOJu0Yyj+ufQ5SlZTNm4oVJqHR6RTbMuSxDeiXajbabT+GC6c1AVa+p5\n b1PGOZJYeV4piG3o/s4Kl1yhaQF2EBfmJE7eo31qhULj6ScpE9xH/HHuz3ffmBaKAp9HiAuK/Fy\n sCb5g15Jl+fk92+r6gldzGoCdNZ5QDJQx3bFIgvfoe7MRaUaviGcr//7QHKdI4SkTbH8nHX5ksx\n NbPalo2JU8/AJ6f/DZ8mXH9192JDMl+1DX6QSODA==", "X-Gm-Gg": "AZuq6aKsRAjfpDXVwgBWbGFhcWIBuWE1o6dKK4EOCHn2jShszywfxqZ9ScpwX9Qd5GV\n T/gCPeGZBmfoL5+PGT+SCHsx2OMU6JHFJmEpY8juD3fnuy9WbY20vwwvPN3NfFQF2BPrnrDJstL\n bd48535mWasY4ZcAaQpJ3Iet00uca72AgitvYpSwbXsuxjBMRNbCqLRFZ2mS/BPvOj63BdMbdBz\n 8ZQBSTxkiYZ8iZDwYgyu2Jc/LmD6WBSTJ3Gpu6Qada7kVk9qZVrx6lWfGjlVfn90nMas+dFd/vh\n MLIXSiN0rcSorLkzt3UH7CCL3Txj6usnD16lod9g38A2WTHt7U/K3pkyuJX9cGvBvqhNi/vwDVy\n TzJ378iHgvG26b5SN7tpTZWXDvlBI9/lLcNgiW7uBK2eUy+E=", "X-Received": [ "by 2002:a05:600c:6216:b0:475:da1a:5418 with SMTP id\n 5b1f17b1804b1-48370e1892dmr6888905e9.1.1770929118785;\n Thu, 12 Feb 2026 12:45:18 -0800 (PST)", "by 2002:a05:600c:6216:b0:475:da1a:5418 with SMTP id\n 5b1f17b1804b1-48370e1892dmr6888635e9.1.1770929118344;\n Thu, 12 Feb 2026 12:45:18 -0800 (PST)" ], "From": "Javier Martinez Canillas <javierm@redhat.com>", "To": "u-boot@lists.denx.de", "Cc": "Heinrich Schuchardt <xypron.glpk@gmx.de>, eballetb@redhat.com,\n Ilias Apalodimas <ilias.apalodimas@linaro.org>,\n Tom Rini <trini@konsulko.com>,\n Javier Martinez Canillas <javierm@redhat.com>", "Subject": "[PATCH v2 2/7] disk: part_dos: Align dos_partition_t with struct\n partition", "Date": "Thu, 12 Feb 2026 21:44:56 +0100", "Message-ID": "<20260212204511.619392-3-javierm@redhat.com>", "X-Mailer": "git-send-email 2.53.0", "In-Reply-To": "<20260212204511.619392-1-javierm@redhat.com>", "References": "<20260212204511.619392-1-javierm@redhat.com>", "MIME-Version": "1.0", "X-Mimecast-Spam-Score": "0", "X-Mimecast-MFC-PROC-ID": "fPt7jBSAujrv4TDFANb7Za8r3XesZKgoNdRV6-QyxLM_1770929120", "X-Mimecast-Originator": "redhat.com", "Content-Transfer-Encoding": "8bit", "content-type": "text/plain; charset=\"US-ASCII\"; x-default=true", "X-BeenThere": "u-boot@lists.denx.de", "X-Mailman-Version": "2.1.39", "Precedence": "list", "List-Id": "U-Boot discussion <u-boot.lists.denx.de>", "List-Unsubscribe": "<https://lists.denx.de/options/u-boot>,\n <mailto:u-boot-request@lists.denx.de?subject=unsubscribe>", "List-Archive": "<https://lists.denx.de/pipermail/u-boot/>", "List-Post": "<mailto:u-boot@lists.denx.de>", "List-Help": "<mailto:u-boot-request@lists.denx.de?subject=help>", "List-Subscribe": "<https://lists.denx.de/listinfo/u-boot>,\n <mailto:u-boot-request@lists.denx.de?subject=subscribe>", "Errors-To": "u-boot-bounces@lists.denx.de", "Sender": "\"U-Boot\" <u-boot-bounces@lists.denx.de>", "X-Virus-Scanned": "clamav-milter 0.103.8 at phobos.denx.de", "X-Virus-Status": "Clean" }, "content": "The dos_partition_t struct defined in part_dos.h is nearly identical to\nthe struct partition defined in part_efi.h. They differ primarily in how\ndefine their starting sector and number of sectors fields.\n\nThe former uses unsigned char arrays while the latter uses __le32 types.\nUsing __le32 is preferable, as it removes the ambiguity and potential\nmisuse of a raw byte array. This also aligns the structure with how the\nLinux kernel defines it nowadays, which is the original source of it.\n\nTo prepare for future consolidation where one of the data structures can\nbe removed, this change aligns both definitions and updates all accessors\nfor dos_partition_t.\n\nSigned-off-by: Javier Martinez Canillas <javierm@redhat.com>\nReviewed-by: Tom Rini <trini@konsulko.com>\n---\n\n(no changes since v1)\n\n disk/part_dos.c | 16 ++++++++--------\n include/part_dos.h | 6 +++---\n 2 files changed, 11 insertions(+), 11 deletions(-)", "diff": "diff --git a/disk/part_dos.c b/disk/part_dos.c\nindex 2545cc6bf5d2..60c3d6773696 100644\n--- a/disk/part_dos.c\n+++ b/disk/part_dos.c\n@@ -49,8 +49,8 @@ static int get_bootable(dos_partition_t *p)\n static void print_one_part(dos_partition_t *p, lbaint_t ext_part_sector,\n \t\t\t int part_num, unsigned int disksig)\n {\n-\tlbaint_t lba_start = ext_part_sector + get_unaligned_le32(p->start4);\n-\tlbaint_t lba_size = get_unaligned_le32(p->size4);\n+\tlbaint_t lba_start = ext_part_sector + get_unaligned_le32(&p->start_sect);\n+\tlbaint_t lba_size = get_unaligned_le32(&p->nr_sects);\n \n \tprintf(\"%3d\\t%-10\" LBAFlength \"u\\t%-10\" LBAFlength\n \t\t\"u\\t%08x-%02x\\t%02x%s%s\\n\",\n@@ -185,7 +185,7 @@ static void print_partition_extended(struct blk_desc *desc,\n \tfor (i = 0; i < 4; i++, pt++) {\n \t\tif (is_extended (pt->sys_ind)) {\n \t\t\tlbaint_t lba_start\n-\t\t\t\t= get_unaligned_le32 (pt->start4) + relative;\n+\t\t\t\t= get_unaligned_le32 (&pt->start_sect) + relative;\n \n \t\t\tprint_partition_extended(desc, lba_start,\n \t\t\t\t\t\t !ext_part_sector ? lba_start :\n@@ -252,8 +252,8 @@ static int part_get_info_extended(struct blk_desc *desc,\n \t\t\telse\n \t\t\t\tinfo->blksz = DOS_PART_DEFAULT_SECTOR;\n \t\t\tinfo->start = (lbaint_t)(ext_part_sector +\n-\t\t\t\t\tget_unaligned_le32(pt->start4));\n-\t\t\tinfo->size = (lbaint_t)get_unaligned_le32(pt->size4);\n+\t\t\t\t\tget_unaligned_le32(&pt->start_sect));\n+\t\t\tinfo->size = (lbaint_t)get_unaligned_le32(&pt->nr_sects);\n \t\t\tpart_set_generic_name(desc, part_num,\n \t\t\t\t\t (char *)info->name);\n \t\t\t/* sprintf(info->type, \"%d, pt->sys_ind); */\n@@ -281,7 +281,7 @@ static int part_get_info_extended(struct blk_desc *desc,\n \tfor (i = 0; i < 4; i++, pt++) {\n \t\tif (is_extended (pt->sys_ind)) {\n \t\t\tlbaint_t lba_start\n-\t\t\t\t= get_unaligned_le32 (pt->start4) + relative;\n+\t\t\t\t= get_unaligned_le32 (&pt->start_sect) + relative;\n \n \t\t\treturn part_get_info_extended(desc, lba_start,\n \t\t\t\t ext_part_sector == 0 ? lba_start : relative,\n@@ -356,8 +356,8 @@ static void mbr_fill_pt_entry(dos_partition_t *pt, lbaint_t start,\n \tpt->sys_ind = sys_ind;\n \tlba_to_chs(start, &pt->cyl, &pt->head, &pt->sector);\n \tlba_to_chs(start + size - 1, &pt->end_cyl, &pt->end_head, &pt->end_sector);\n-\tput_unaligned_le32(relative, &pt->start4);\n-\tput_unaligned_le32(size, &pt->size4);\n+\tput_unaligned_le32(relative, &pt->start_sect);\n+\tput_unaligned_le32(size, &pt->nr_sects);\n }\n \n int write_mbr_partitions(struct blk_desc *dev,\ndiff --git a/include/part_dos.h b/include/part_dos.h\nindex 505582242281..92956d530637 100644\n--- a/include/part_dos.h\n+++ b/include/part_dos.h\n@@ -30,8 +30,8 @@ typedef struct dos_partition {\n \tunsigned char end_head;\t\t/* end head\t\t\t\t*/\n \tunsigned char end_sector;\t/* end sector\t\t\t\t*/\n \tunsigned char end_cyl;\t\t/* end cylinder\t\t\t\t*/\n-\tunsigned char start4[4];\t/* starting sector counting from 0\t*/\n-\tunsigned char size4[4];\t\t/* nr of sectors in partition\t\t*/\n-} dos_partition_t;\n+\t__le32 start_sect;\t\t/* starting sector counting from 0\t*/\n+\t__le32 nr_sects;\t\t/* nr of sectors in partition\t\t*/\n+} __packed dos_partition_t;\n \n #endif\t/* _DISK_PART_DOS_H */\n", "prefixes": [ "v2", "2/7" ] }