From nobody Sun Oct 02 04:29:26 2022 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 4Mg9wQ6y1rz4dt3h; Sun, 2 Oct 2022 04:29:26 +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 4Mg9wQ6Nmlz44Dh; Sun, 2 Oct 2022 04:29:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1664684966; 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=QGkHwtK9qay16Y02gJVvCAJWrWSIOknnd2hG8sxO5Kw=; b=kk0Cs/GJhFDvwtV5XbPWIGGBMmy73rPKScAwUPaPXWypEOwpjIqzK3jACvPk1KDctlPr/g GYJSllnari9g8yXE8mK1/M3JFFzcChpSeYuPz/yVGaZ6hEb4/CVe7R+GfM/3AIhy5SGSh8 wK9tzx/gMVrPDnNW5VVUfh7BZlRLZNGDD4GiEF0NdjLjOatQsMsn0wG9B+jjOex6Asz7jG lcIcFAjyI6GbPmVC3XlIRD6y/ucMyKv/jtGYXa6Lq/PSJTM85yq8kafuEJ4crBQvNWDvAc d+0hcuoizdOMSeG6KNZxH/vSZd+zGyMoYp1EK6n89e2Hy1Cammq2MBDGjjwFAg== 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 4Mg9wQ5VzYzlbj; Sun, 2 Oct 2022 04:29:26 +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 2924TQp0058178; Sun, 2 Oct 2022 04:29:26 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 2924TQxK058177; Sun, 2 Oct 2022 04:29:26 GMT (envelope-from git) Date: Sun, 2 Oct 2022 04:29:26 GMT Message-Id: <202210020429.2924TQxK058177@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Warner Losh Subject: git: 33491120e5fa - stable/13 - fd_probe: only define unit on x86, other platforms don't use this code 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: imp X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 33491120e5fa4511367b5779a84d32922ccb784b Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1664684966; 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=QGkHwtK9qay16Y02gJVvCAJWrWSIOknnd2hG8sxO5Kw=; b=jlW3aRwq7WgWIAz7mKCv27pE2JXlTwlzZUlQNXx9zZmJEv6EqfPpdx4Y/M4Wrh/AJSL0s5 HkAI8U6i6SixCm9fihCUiqb5OK9vcouad0HkOWftlanUoTX0c6vQUgYozHKghgZMmYhMdI 90lMWYmvkvip+pMNBG03TkR5vbqc6aT05/5oOPm6G6uuZjSO8QH9j0n+4l5X1cR/wIw5D2 UW677NZ10T3ZN8DU8y7h0su6AXyrwldO8fWBmVnWgZYJVIPi0jQ5eBUQJ2OxYbNS/I0AZf nSHUO4LOmXlMrFpYe95mAkacPiXTnnpmmNa1dMUcEqiilxvMeLE5bTDvBORC9g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1664684966; a=rsa-sha256; cv=none; b=sjO6+u7I/g/JcoLnnZhzjTNVRrBzDKcufc9lpLqjVM3wiZK/mqwLOI0VYV0DEuJw7tnBYp 1Pd99wXhkxkqThHpER5JmANFv1mgmShrGORvmRh1+c5ldBHpBo2/IfbLME5qPizyPlznCl YmeiCGNphgCh+3eaGsusNJNREBHIXQJy2nBu4z/FAUaFGgrH/V1Ccnpv3tcnHGH800U2YD o9mH5B4AzNmzTrNA2KaNHgKNbEjFkNdM5odwRhDbVwq32zxYlT3zCdB/b3AWM6w5lQ+9Po mvr9pYGwYE5Rt6WxlOQUe8MxhZEAQhfwgP/iHLCllDb6ECj3GPs/g2+K6fl27w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=33491120e5fa4511367b5779a84d32922ccb784b commit 33491120e5fa4511367b5779a84d32922ccb784b Author: Warner Losh AuthorDate: 2022-07-08 17:53:30 +0000 Commit: Warner Losh CommitDate: 2022-10-02 04:25:52 +0000 fd_probe: only define unit on x86, other platforms don't use this code Sponsored by: Netflix (cherry picked from commit 05d3c5fd182eeb33075ee14e2802c94882dc2c41) --- sys/dev/fdc/fdc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/dev/fdc/fdc.c b/sys/dev/fdc/fdc.c index 11262231c3b2..4e771eead119 100644 --- a/sys/dev/fdc/fdc.c +++ b/sys/dev/fdc/fdc.c @@ -1897,7 +1897,9 @@ fdc_print_child(device_t me, device_t child) static int fd_probe(device_t dev) { +#if defined(__i386__) || defined(__amd64__) int unit; +#endif int i; u_int st0, st3; struct fd_data *fd; @@ -1913,7 +1915,6 @@ fd_probe(device_t dev) fd->dev = dev; fd->fdc = fdc; fd->fdsu = fdsu; - unit = device_get_unit(dev); /* Auto-probe if fdinfo is present, but always allow override. */ type = flags & FD_TYPEMASK; @@ -1927,6 +1928,7 @@ fd_probe(device_t dev) } #if defined(__i386__) || defined(__amd64__) + unit = device_get_unit(dev); if (fd->type == FDT_NONE && (unit == 0 || unit == 1)) { /* Look up what the BIOS thinks we have. */ if (unit == 0)