From nobody Sun Apr 23 13:30:14 2023 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Q48Jl1NxXz45R8j; Sun, 23 Apr 2023 13:30:15 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Q48Jk4jnQz49L1; Sun, 23 Apr 2023 13:30:14 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1682256614; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ToxL9s4lWeTOEpOMzOpkKniO/UUa/oe4UH1wBoVCbEs=; b=tDevoEFear9Lj5ujrmDPSyFEMZxhNa1bn0ms8BLgAxqC9GysED7GmH13llp4N2PTsFUvAO MSV8wl9Rskt1TcTpW11h+WP/Em6LPXFajyD8qyeGdZIt+vYFJW745s1WMD7HWLpZnwIGWF Yxti2dS1pVry00qzyq16s1n9koQH+NSmAJ0PZI33m/cLUkqVVW6441TW3CjeZd8B7PdQFk zWAkvkdWZByPBsxmYlEcTTZhuuCLQEqMGTANHPcG0+avf6biUzltQBJBMYX72H3JPAqD3q 02m9p9YICZWvC2hTicpjx1MlNsjE1SQxz/oyFhShNBOTaSuy9MPsobRXzvl6gA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1682256614; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ToxL9s4lWeTOEpOMzOpkKniO/UUa/oe4UH1wBoVCbEs=; b=pon/bwoxcIMXGW2vq2Vpc4B5GkNFb509m6vQblCY4W8co67bZe02paNSZ5wBuo/pIDX3P/ qV1/eAeWDYRQBqwmIMHOkqMbz9Dl1i7xMiyTbuG44NfdwOdaF7uT8BH3JXUVYY+kUtH3eE NJ6WUy56J0LduelHWzfpq/SoLftKqtIO00TGfUzX/4pQNY3XfhHtGqBZllOL+x0hGzKvvW sNWjY22lQ89AvVEvj2lx44BxVwwmsbkPV5LNAL0AYD7kMUsHaUnwjq80drvR32z+ikLf23 kOcgW8F6klyVEAPBrfdQorDAAIqyNxw4dMz44k59xdRzZOpMPmWhSZdoBhSClg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1682256614; a=rsa-sha256; cv=none; b=ms12LpAANwLKOysUTsBucHhVX7x/REKxY9UT6N0sI+Fc3Bo7RGKimfv5nCsiFeBb6X9WQ+ QZioqzFoNOv6r5KEQYZL2vmvRk5c9/4glHdFKzCpBI7JFMXWNoVStsT0Yl9i3RUEZX0BG2 XmEowIp7ti7caGsuX2pOM8ZL1kppjI3sqNZQ/FsOWa40o2UgjPYgV9I1U+noKSocmDIBh2 PLRuuh+hDlxfitTOezsAg3Vrc8G8l30t6IRTQ76kTbyzAqMmfn74P7+grihzJakYYPPdp+ dmf9dfgcIWEmkadW1/MFou/QQkdqZQkd1zE3Ehvu8Ch0afAF88EwcHYGUtGO+A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Q48Jk3fD0zlHf; Sun, 23 Apr 2023 13:30:14 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 33NDUE2L090387; Sun, 23 Apr 2023 13:30:14 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 33NDUEt8090380; Sun, 23 Apr 2023 13:30:14 GMT (envelope-from git) Date: Sun, 23 Apr 2023 13:30:14 GMT Message-Id: <202304231330.33NDUEt8090380@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 0e8953b94b74 - main - LinuxKPI: pci.h: always initialize return value List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: bz X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 0e8953b94b7481a53945cbd1e16517773996e16e Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=0e8953b94b7481a53945cbd1e16517773996e16e commit 0e8953b94b7481a53945cbd1e16517773996e16e Author: Bjoern A. Zeeb AuthorDate: 2023-04-20 15:59:33 +0000 Commit: Bjoern A. Zeeb CommitDate: 2023-04-23 13:29:30 +0000 LinuxKPI: pci.h: always initialize return value In pcie_capability_read_*() always initialize the return value to avoid warnings of uninitialized values in callers. Sponsored by: The FreeBSD Foundation MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D39721 --- sys/compat/linuxkpi/common/include/linux/pci.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/pci.h b/sys/compat/linuxkpi/common/include/linux/pci.h index 8077a75c4dd9..9b2e9269d4d4 100644 --- a/sys/compat/linuxkpi/common/include/linux/pci.h +++ b/sys/compat/linuxkpi/common/include/linux/pci.h @@ -1178,6 +1178,7 @@ static bool pcie_capability_reg_implemented(struct pci_dev *dev, int pos) static inline int pcie_capability_read_dword(struct pci_dev *dev, int pos, u32 *dst) { + *dst = 0; if (pos & 3) return -EINVAL; @@ -1190,6 +1191,7 @@ pcie_capability_read_dword(struct pci_dev *dev, int pos, u32 *dst) static inline int pcie_capability_read_word(struct pci_dev *dev, int pos, u16 *dst) { + *dst = 0; if (pos & 3) return -EINVAL;