From nobody Mon May 6 17:15:57 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org ARC-Seal: i=1; a=rsa-sha256; t=1656614245; cv=none; d=zohomail.com; s=zohoarc; b=egT4/GreD6SOm1CpEVhjV2mACBKpTqo3UN5QbbqYiI8zTw8OPSCI7q44L5DTA16kFjewc8JEZ7Ho7wgz+olNl5Rx2rSqi4qckFG+p9dwbQHIQ1ibVZFSaM7vFFbf0Ouw3AVfD4Avy4VgKZztQbDLOe65vEjGoUGt1N8BBfo8ZTs= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1656614245; h=Content-Transfer-Encoding:Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=EfathmZv19nq32cxJTKgih5SUnMMa3ZNjaInUHYRRhE=; b=jvzfHJIgipWImdp6UdOfL/D8lO/JiRVkFC9saBpoGsMk8j6Iu8W/2mu/B7VPRAdZWbAEIyqX9pigdAwvQ7Gul1kJ4uG6klvBuCbxskyXaOzTtjPtMnWgLQdlr8YzK1v+WVrd143ylZvKwu4h8wQK7CcT66qZ+DvUmtbjKeCs0mA= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1656614245581500.19327456000417; Thu, 30 Jun 2022 11:37:25 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.358667.587957 (Exim 4.92) (envelope-from ) id 1o6z2G-0001EW-8b; Thu, 30 Jun 2022 18:37:04 +0000 Received: by outflank-mailman (output) from mailman id 358667.587957; Thu, 30 Jun 2022 18:37:04 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1o6z2G-0001EP-4w; Thu, 30 Jun 2022 18:37:04 +0000 Received: by outflank-mailman (input) for mailman id 358667; Thu, 30 Jun 2022 18:37:02 +0000 Received: from mail.xenproject.org ([104.130.215.37]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1o6z2E-0001EJ-CM for xen-devel@lists.xenproject.org; Thu, 30 Jun 2022 18:37:02 +0000 Received: from xenbits.xenproject.org ([104.239.192.120]) by mail.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1o6z2E-0002Tg-7b; Thu, 30 Jun 2022 18:37:02 +0000 Received: from 54-240-197-232.amazon.com ([54.240.197.232] helo=dev-dsk-jgrall-1b-035652ec.eu-west-1.amazon.com) by xenbits.xenproject.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1o6z2D-0000ey-Tp; Thu, 30 Jun 2022 18:37:02 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=xen.org; s=20200302mail; h=Content-Transfer-Encoding:MIME-Version:Message-Id:Date: Subject:Cc:To:From; bh=EfathmZv19nq32cxJTKgih5SUnMMa3ZNjaInUHYRRhE=; b=dkuK7T PrQjsr8TrzB4r/UwFeeG3A1Pk+OTM+OVUpgm3zFqTfTz2+dnWuIUUDYRmPbXG5UAoAQyg4jSwuGjc KOMNjPE0PZmrkIqI/7nx14yZFJ26FnH1OSBswI6I07cnO28vYMSJzcpolp16YTXv0VE18JmWLqdkt sDOYk76pZgQ=; From: Julien Grall To: xen-devel@lists.xenproject.org Cc: jbeulich@suse.com, Julien Grall , Juergen Gross Subject: [PATCH v3] public/io: xs_wire: Document that new errors should be added at the end Date: Thu, 30 Jun 2022 19:36:55 +0100 Message-Id: <20220630183655.44391-1-julien@xen.org> X-Mailer: git-send-email 2.32.0 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @xen.org) X-ZM-MESSAGEID: 1656614246611100001 Content-Type: text/plain; charset="utf-8" From: Julien Grall Some tools (e.g. xenstored) always expect EINVAL to be first in xsd_errors. To be conservative, mandate that new errors should be added at the end of the array. Signed-off-by: Julien Grall Reviewed-by: Henry Wang Reviewed-by: Juergen Gross ---- Changes in v3: - Mandate that new errors should be added at the end. Changes in v2: - New patch --- xen/include/public/io/xs_wire.h | 1 + 1 file changed, 1 insertion(+) diff --git a/xen/include/public/io/xs_wire.h b/xen/include/public/io/xs_wir= e.h index c1ec7c73e3b1..a4d954cb05aa 100644 --- a/xen/include/public/io/xs_wire.h +++ b/xen/include/public/io/xs_wire.h @@ -76,6 +76,7 @@ static struct xsd_errors xsd_errors[] __attribute__((unused)) #endif =3D { + /* /!\ New errors should be added at the end of the array. */ XSD_ERROR(EINVAL), XSD_ERROR(EACCES), XSD_ERROR(EEXIST), --=20 2.32.0