From nobody Thu Oct 17 13:27:29 2024 X-Original-To: dev-commits-src-main@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 4XTpXx4PDMz5Z11X; Thu, 17 Oct 2024 13:27:29 +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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4XTpXx3fdKz4jK5; Thu, 17 Oct 2024 13:27:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1729171649; 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=zm0uE3kWajypTG06lE9YfAX8uE5nB/TVDk48j3fVoTM=; b=fG99xpQjNuuyS+vM8H+HN+mx2B/dlb1dZjnoCk9sf6YyKFJX4BHRnBEK9DIJ9fuaRAzxPU 55RPI8ZvderrfrycuzUMVEcQFokTimbIVdpBwFnmO8Ozx1p/oQXY4IrEa1a52DZc8zLOkf 8DppYZD5YDrF5BG3QiGTGvSGcYip61siT6kDHyWVn6ZJjcTYhqvV2h0gz1QvpqMbCg8sRG h4/ypLwUVevkGIuslNSgKd0XFfNTPVSJIZHAk3NW856VRM4S3zmoFAEX/nM47GedKrc1aK l6PhImvGHyIaSQRDlTkEcO3B7l3bd4lFGfuCV2EQRTqPbvDA+OhDOuZjpnOQHw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1729171649; 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=zm0uE3kWajypTG06lE9YfAX8uE5nB/TVDk48j3fVoTM=; b=nxv19JaCI8i0Cs1SdfGcvZvFnKyRGpkGBtS1mo3vDiAtgcu4Un8esoyMcd3rP7BM0iPMhw z5REqh1awefUOM5tHgSg0A440JpVPuDH/j8nV719MkRfhQ9cs5JhvYLzJOPLu/M3z2l6uD 6UgmLIbzNLc6O0B6K9DgWHsh1EDIXzi2kMkwi5moFb8Ts6ftmXGjdBiO+jvBgg0XRD+jQo zIuQwd5jsKMH23vLgT2fP+eUKVebklp3ncJlxJm5ZAIb6AdQ6uaalkTjhYh/3sktK9WSR4 U2lzyJDIdWw8QI1EevwAS0EGvVGtbk4kX70BjTt3YVpnmOJwEKfM/pqpe+G1ng== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1729171649; a=rsa-sha256; cv=none; b=gBNtObbymvHu00p1fp5K8KFb93ReNzaxmnrLVoCGHiQXJPbuzqlidXZ3U9xKJ46NUCc+dt Zt4PWNoKv43Cv8zaj3fw8LF2YDd6CmxixgBi5rzNLYTDQ09o8EeRqESJtxjY61Tiv0yDsG irPRtPsZon/Gql3Gm6garPXmROdpckg+P1YbtgbBEbjpkWWbiONzVkpZhkODG1SbJDSLj9 /KoRK8LGxyYNUEOfym117WnvTO+oOl2RsR5VBH9MM8SpF1iK4sbWNmYuvubCb/ChDZE8jj 5BEoR0Du7wxb4jOShDZMdQ3bH8J6ffVtt7tG3X3wMUuSjvxL7UaHhXtTsUVE3Q== 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 4XTpXx3G0qzrm9; Thu, 17 Oct 2024 13:27:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 49HDRTPL011534; Thu, 17 Oct 2024 13:27:29 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 49HDRTwF011531; Thu, 17 Oct 2024 13:27:29 GMT (envelope-from git) Date: Thu, 17 Oct 2024 13:27:29 GMT Message-Id: <202410171327.49HDRTwF011531@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: 157e93e0e813 - main - LinuxKPI: pci: rename PCI_IRQ_LEGACY to PCI_IRQ_INTX List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 157e93e0e8138fbaa6ab5d5b20b0c23f903667a6 Auto-Submitted: auto-generated The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=157e93e0e8138fbaa6ab5d5b20b0c23f903667a6 commit 157e93e0e8138fbaa6ab5d5b20b0c23f903667a6 Author: Bjoern A. Zeeb AuthorDate: 2024-09-26 21:13:35 +0000 Commit: Bjoern A. Zeeb CommitDate: 2024-10-17 13:27:05 +0000 LinuxKPI: pci: rename PCI_IRQ_LEGACY to PCI_IRQ_INTX PCI_IRQ_LEGACY was added in 366d68f28379 (likely) for rtw88 only. The define now got renamed and I cannot find any other use but rtw88 and rtw89. We keep the old name as comapt while driver updates are in progress enabling it defining LINUXKPI_VERSION for the two drivers. Sponsored by; The FreeBSD Foundation MFC after: 3 days Differential Revision: https://reviews.freebsd.org/D46822 --- sys/compat/linuxkpi/common/include/linux/pci.h | 8 ++++++-- sys/compat/linuxkpi/common/src/linux_pci.c | 2 +- sys/modules/rtw88/Makefile | 1 + sys/modules/rtw89/Makefile | 1 + 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/pci.h b/sys/compat/linuxkpi/common/include/linux/pci.h index a2de534fcb60..c6fc1195f71b 100644 --- a/sys/compat/linuxkpi/common/include/linux/pci.h +++ b/sys/compat/linuxkpi/common/include/linux/pci.h @@ -233,10 +233,14 @@ extern const char *pci_power_names[6]; #define PCI_L1SS_CTL1 0x8 #define PCI_L1SS_CTL1_L1SS_MASK 0xf -#define PCI_IRQ_LEGACY 0x01 +#define PCI_IRQ_INTX 0x01 #define PCI_IRQ_MSI 0x02 #define PCI_IRQ_MSIX 0x04 -#define PCI_IRQ_ALL_TYPES (PCI_IRQ_MSIX|PCI_IRQ_MSI|PCI_IRQ_LEGACY) +#define PCI_IRQ_ALL_TYPES (PCI_IRQ_MSIX|PCI_IRQ_MSI|PCI_IRQ_INTX) + +#if defined(LINUXKPI_VERSION) && (LINUXKPI_VERSION >= 60800) +#define PCI_IRQ_LEGACY PCI_IRQ_INTX +#endif struct pci_dev; diff --git a/sys/compat/linuxkpi/common/src/linux_pci.c b/sys/compat/linuxkpi/common/src/linux_pci.c index 3376d93053dc..366731081072 100644 --- a/sys/compat/linuxkpi/common/src/linux_pci.c +++ b/sys/compat/linuxkpi/common/src/linux_pci.c @@ -1306,7 +1306,7 @@ out: if (error == 0 && pdev->msi_enabled) return (pdev->dev.irq_end - pdev->dev.irq_start); } - if (flags & PCI_IRQ_LEGACY) { + if (flags & PCI_IRQ_INTX) { if (pdev->irq) return (1); } diff --git a/sys/modules/rtw88/Makefile b/sys/modules/rtw88/Makefile index b0e6b59b708e..a63f769cb878 100644 --- a/sys/modules/rtw88/Makefile +++ b/sys/modules/rtw88/Makefile @@ -32,6 +32,7 @@ SRCS+= opt_wlan.h opt_inet6.h opt_inet.h #CFLAGS+= -ferror-limit=0 CFLAGS+= -DKBUILD_MODNAME='"rtw88"' +CFLAGS+= -DLINUXKPI_VERSION=60800 CFLAGS+= -I${DEVRTW88DIR} CFLAGS+= ${LINUXKPI_INCLUDES} diff --git a/sys/modules/rtw89/Makefile b/sys/modules/rtw89/Makefile index f13924e1aa5b..87e1b133867d 100644 --- a/sys/modules/rtw89/Makefile +++ b/sys/modules/rtw89/Makefile @@ -32,6 +32,7 @@ SRCS+= ${LINUXKPI_GENSRCS} SRCS+= opt_wlan.h opt_inet6.h opt_inet.h opt_acpi.h CFLAGS+= -DKBUILD_MODNAME='"rtw89"' +CFLAGS+= -DLINUXKPI_VERSION=60800 CFLAGS+= -I${DEVRTW89DIR} CFLAGS+= ${LINUXKPI_INCLUDES}