From nobody Tue Feb 10 09:28:20 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of _spf.google.com designates 209.85.221.42 as permitted sender) client-ip=209.85.221.42; envelope-from=philippe.mathieu.daude@gmail.com; helo=mail-wr1-f42.google.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of _spf.google.com designates 209.85.221.42 as permitted sender) smtp.mailfrom=philippe.mathieu.daude@gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1635613705; cv=none; d=zohomail.com; s=zohoarc; b=LGGG3voKHNxdJJD39UyyXU7imxdqVGsJXJ3KwrCuV6n939fwWsOci/zecIc270ZCI6tgO2fzH5vRC79vsBi814mcZpxr49tV6EQIz9cWf+tU/da60/IAZlKWN+tc+4R9JToe0ZZ2g2RFzq6Yi3DNyviGEziYwMS0oVLAOkqbAn4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1635613705; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:MIME-Version:Message-ID:References:Sender:Subject:To; bh=ZLUlGGCAE4OsJnGPcZDW1ai5vTzjA4RoqtmCsvfI3/w=; b=hlbcizlnvNJbIeiDrtwDiQL7DFSmomwfUH+SleEzY1CnUufoe+6P+KdYmgHmV6IZtg/BdshJKVMP/BSzRkbdVEx454E4cHtXrIb2YKjMCypidGcwWHGSO2gXLv1kh9BhFYcPGoyTJoIk/kMgMHqq9XbVjzZ62+J6fcc7KvAG7Uk= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of _spf.google.com designates 209.85.221.42 as permitted sender) smtp.mailfrom=philippe.mathieu.daude@gmail.com Received: from mail-wr1-f42.google.com (mail-wr1-f42.google.com [209.85.221.42]) by mx.zohomail.com with SMTPS id 1635613705573794.7852372416215; Sat, 30 Oct 2021 10:08:25 -0700 (PDT) Received: by mail-wr1-f42.google.com with SMTP id d13so21605365wrf.11 for ; Sat, 30 Oct 2021 10:08:25 -0700 (PDT) Return-Path: Return-Path: Received: from x1w.. (62.red-83-57-168.dynamicip.rima-tde.net. [83.57.168.62]) by smtp.gmail.com with ESMTPSA id h18sm3031789wre.46.2021.10.30.10.08.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 30 Oct 2021 10:08:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=ZLUlGGCAE4OsJnGPcZDW1ai5vTzjA4RoqtmCsvfI3/w=; b=oWUqQNFnlr9G+lJOmX8G0cck0hbbWiF6Wkj0vbqW/86RBWHjibhtA1pofbQbfFys5M z/E8pmPvrBsEsuC1eDQ71Ii7Z8AOShXaay3MH2fydGrNAM45dOyTLe43MBOY5siWas3O tWWyVmkub1+jxMor7kTplLSScuGtJhxbZv3Ky/H7HKxeDe4vVXKJaN325n7cMM0xMcBt /BuT7zsDjyzDKNSS6KqxUc0z/TY0DD2XMUyswrYy4HbP5XoXRapBw/Ln5L3E2lnzKVv5 Bw+becQAaFcHtxnU1dcAo2DWtb3nncfWY7j8VSKBCJTXXWUir24JVSSQTMQiEF0O6LRg jQuw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=ZLUlGGCAE4OsJnGPcZDW1ai5vTzjA4RoqtmCsvfI3/w=; b=A7iFZLPhGS0a+OTZRn5MNLgbFyV4kwMm+oCA+GBLNosM/aSZL7EWIsIeRKLEMZdXqy gsEyJJd9jUNuplklGOOETBG4csdxVpJYtXDE347cGLQgTGUG8kZZnvZXAIQF7UQfrv/M MmV3Q/wyTgZuCt16rBiBK06apLmFwOV8ESMeMrNkWDQTi+ciUN3spzLZTnUjAng1fkRG Lqq8egrCeujhau/founkNjRiscNjNT9L1cLcaWY04xE4arUGFHWsxywm9zdaTUeuebvU 93zHlLVwn7B2naQ5wmg+v/zPLTL7TPpsh6NLGYxK8N5yGBm5X9sUb3bFyiKujZYFPmHU DHYg== X-Gm-Message-State: AOAM532eTZKeR6Kq3vNANulXm1uYb5YmpnIFilg7CUmjAWrGtsuu82In YJr7aAzRsmF6flg/loqBYkc= X-Google-Smtp-Source: ABdhPJw7zHuyZWXW96vheHANmloQ+ut3j/8wK8/m+nG1F58xAYAoBrskH9Dc4vFGP1D1a0GxTnByFQ== X-Received: by 2002:a05:6000:1689:: with SMTP id y9mr23771532wrd.52.1635613703902; Sat, 30 Oct 2021 10:08:23 -0700 (PDT) Sender: =?UTF-8?Q?Philippe_Mathieu=2DDaud=C3=A9?= From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Cc: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , Yoshinori Sato , Magnus Damm , Paolo Bonzini , BALATON Zoltan , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Subject: [PULL 26/30] hw/intc/sh_intc: Remove unneeded local variable initialisers Date: Sat, 30 Oct 2021 19:06:11 +0200 Message-Id: <20211030170615.2636436-27-f4bug@amsat.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211030170615.2636436-1-f4bug@amsat.org> References: <20211030170615.2636436-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1635613705918100001 From: BALATON Zoltan The sh_intc_locate function will either init these or not return so no need to initialise them. Signed-off-by: BALATON Zoltan Reviewed-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <15e04aa665c68ab5df47bbf505346d413be2fc1c.1635541329.git.balato= n@eik.bme.hu> Signed-off-by: Philippe Mathieu-Daud=C3=A9 --- hw/intc/sh_intc.c | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/hw/intc/sh_intc.c b/hw/intc/sh_intc.c index 3356b422022..c9b0b0c1ecc 100644 --- a/hw/intc/sh_intc.c +++ b/hw/intc/sh_intc.c @@ -195,14 +195,13 @@ static void sh_intc_toggle_mask(struct intc_desc *des= c, intc_enum id, } } =20 -static uint64_t sh_intc_read(void *opaque, hwaddr offset, - unsigned size) +static uint64_t sh_intc_read(void *opaque, hwaddr offset, unsigned size) { struct intc_desc *desc =3D opaque; - intc_enum *enum_ids =3D NULL; - unsigned int first =3D 0; - unsigned int width =3D 0; - unsigned int mode =3D 0; + intc_enum *enum_ids; + unsigned int first; + unsigned int width; + unsigned int mode; unsigned long *valuep; =20 sh_intc_locate(desc, (unsigned long)offset, &valuep, @@ -215,12 +214,12 @@ static void sh_intc_write(void *opaque, hwaddr offset, uint64_t value, unsigned size) { struct intc_desc *desc =3D opaque; - intc_enum *enum_ids =3D NULL; - unsigned int first =3D 0; - unsigned int width =3D 0; - unsigned int mode =3D 0; - unsigned int k; + intc_enum *enum_ids; + unsigned int first; + unsigned int width; + unsigned int mode; unsigned long *valuep; + unsigned int k; unsigned long mask; =20 trace_sh_intc_write(size, (uint64_t)offset, value); --=20 2.31.1