From nobody Thu Dec 25 17:55:46 2025 Received: from madrid.collaboradmins.com (madrid.collaboradmins.com [46.235.227.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 32ABE6D1A8 for ; Fri, 12 Jan 2024 13:21:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="nBq3PbDy" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1705065674; bh=L+28NgGOIiCoYRdT/O15SQx+OK5WNhSsQoOnP70V+rE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=nBq3PbDy9JluN0ABov4e5gHyDfO1sVRroFlx7r4gUxjxDcW697MV7/glA4Gc5wekN aCyiXzLcivCObF0Hb6Ovw/30z2prfulK6/ACxJpSw6753CYzeEYC763Ds3xwaasjVs NYeux67OafiJt9ChjzFbcrJ8/ZjXMkiOG8PiU3eV6ZNXt8N25ou5EK7ej6WprCrR3e UMWv+QBiDFd9WwC6aOyjkmvIidjt5mVSzSNm3DJf2XJQscd8rUFg1PKfqxf+qyxavE nQ8pfuAXgicJP5jCBwDzXZvb1tbDNW0+F2UX0CIMT3DeRIR6rqgaDlx1LZenboqtUZ 5l/MEP1Gd0kkg== Received: from localhost.localdomain (zone.collabora.co.uk [167.235.23.81]) (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) (No client certificate requested) (Authenticated sender: nfraprado) by madrid.collaboradmins.com (Postfix) with ESMTPSA id B540E3782031; Fri, 12 Jan 2024 13:21:11 +0000 (UTC) From: =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= To: Tzung-Bi Shih Cc: kernel@collabora.com, AngeloGioacchino Del Regno , chrome-platform@lists.linux.dev, =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= , Brian Norris , Julius Werner , linux-kernel@vger.kernel.org Subject: [PATCH v2 1/7] firmware: coreboot: Generate modalias uevent for devices Date: Fri, 12 Jan 2024 10:18:30 -0300 Message-ID: <20240112131857.900734-2-nfraprado@collabora.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240112131857.900734-1-nfraprado@collabora.com> References: <20240112131857.900734-1-nfraprado@collabora.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Generate a modalias uevent for devices in the coreboot bus to allow userspace to automatically load the corresponding modules. Acked-by: Brian Norris Signed-off-by: N=C3=ADcolas F. R. A. Prado Reviewed-by: AngeloGioacchino Del Regno --- (no changes since v1) drivers/firmware/google/coreboot_table.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/drivers/firmware/google/coreboot_table.c b/drivers/firmware/go= ogle/coreboot_table.c index 2a4469bf1b81..c1b9a9e8e8ed 100644 --- a/drivers/firmware/google/coreboot_table.c +++ b/drivers/firmware/google/coreboot_table.c @@ -53,11 +53,20 @@ static void coreboot_bus_remove(struct device *dev) driver->remove(device); } =20 +static int coreboot_bus_uevent(const struct device *dev, struct kobj_ueven= t_env *env) +{ + struct coreboot_device *device =3D CB_DEV(dev); + u32 tag =3D device->entry.tag; + + return add_uevent_var(env, "MODALIAS=3Dcoreboot:t%08X", tag); +} + static struct bus_type coreboot_bus_type =3D { .name =3D "coreboot", .match =3D coreboot_bus_match, .probe =3D coreboot_bus_probe, .remove =3D coreboot_bus_remove, + .uevent =3D coreboot_bus_uevent, }; =20 static void coreboot_device_release(struct device *dev) --=20 2.43.0 From nobody Thu Dec 25 17:55:46 2025 Received: from madrid.collaboradmins.com (madrid.collaboradmins.com [46.235.227.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 41A586D1A4; Fri, 12 Jan 2024 13:21:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="T3qA3z5I" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1705065680; bh=sPz7qlYsrHlq3cCOtHZi7BOxHqEKVr3tJDgaD7Qlm4I=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=T3qA3z5IeURvAorefJ8yBC9ViApTUBJv7sEOilZu1dK9dPr99ixr/x5svUv3Yc5xQ j3hW3cAO3CKI73X3LCB6LyfIviNFq8IOOCkJWSj/b2SDVr2KH3hNsm7Ks6P1SZBvK2 sHkvvm2bN8OLRPTVc2UU3pRk+0hveFvAsNqDv5PE7yX+xfeHVsqKVEqCwVLplS2YvO YRFiZbvuNUZ/5cV5CyYuYP1iRikzbXEmE/gwzMfWZr3G2RpxOHEcEgYNDcvvsGWQ3l DmdrGOnVYVpVKwkpAfd/G2poivJI35vMzqBeQl3vaySdsB3fhd/tFdCeVSADM1Ktlk h8PtR3BdBI3RA== Received: from localhost.localdomain (zone.collabora.co.uk [167.235.23.81]) (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) (No client certificate requested) (Authenticated sender: nfraprado) by madrid.collaboradmins.com (Postfix) with ESMTPSA id 685293782032; Fri, 12 Jan 2024 13:21:15 +0000 (UTC) From: =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= To: Tzung-Bi Shih Cc: kernel@collabora.com, AngeloGioacchino Del Regno , chrome-platform@lists.linux.dev, =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= , Abhijit Gangurde , Andy Shevchenko , Greg Kroah-Hartman , Masahiro Yamada , Nathan Chancellor , Nicolas Schier , Nipun Gupta , Pieter Jansen van Vuuren , Umang Jain , linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 2/7] firmware: coreboot: Generate aliases for coreboot modules Date: Fri, 12 Jan 2024 10:18:31 -0300 Message-ID: <20240112131857.900734-3-nfraprado@collabora.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240112131857.900734-1-nfraprado@collabora.com> References: <20240112131857.900734-1-nfraprado@collabora.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Generate aliases for coreboot modules to allow automatic module probing. Signed-off-by: N=C3=ADcolas F. R. A. Prado Reviewed-by: AngeloGioacchino Del Regno --- (no changes since v1) include/linux/mod_devicetable.h | 8 ++++++++ scripts/mod/devicetable-offsets.c | 3 +++ scripts/mod/file2alias.c | 10 ++++++++++ 3 files changed, 21 insertions(+) diff --git a/include/linux/mod_devicetable.h b/include/linux/mod_devicetabl= e.h index f458469c5ce5..24e0dcfde809 100644 --- a/include/linux/mod_devicetable.h +++ b/include/linux/mod_devicetable.h @@ -960,4 +960,12 @@ struct vchiq_device_id { char name[32]; }; =20 +/** + * struct coreboot_device_id - Identifies a coreboot table entry + * @tag: tag ID + */ +struct coreboot_device_id { + __u32 tag; +}; + #endif /* LINUX_MOD_DEVICETABLE_H */ diff --git a/scripts/mod/devicetable-offsets.c b/scripts/mod/devicetable-of= fsets.c index e91a3c38143b..518200813d4e 100644 --- a/scripts/mod/devicetable-offsets.c +++ b/scripts/mod/devicetable-offsets.c @@ -274,5 +274,8 @@ int main(void) DEVID(vchiq_device_id); DEVID_FIELD(vchiq_device_id, name); =20 + DEVID(coreboot_device_id); + DEVID_FIELD(coreboot_device_id, tag); + return 0; } diff --git a/scripts/mod/file2alias.c b/scripts/mod/file2alias.c index 4829680a0a6d..5d1c61fa5a55 100644 --- a/scripts/mod/file2alias.c +++ b/scripts/mod/file2alias.c @@ -1494,6 +1494,15 @@ static int do_vchiq_entry(const char *filename, void= *symval, char *alias) return 1; } =20 +/* Looks like: coreboot:tN */ +static int do_coreboot_entry(const char *filename, void *symval, char *ali= as) +{ + DEF_FIELD(symval, coreboot_device_id, tag); + sprintf(alias, "coreboot:t%08X", tag); + + return 1; +} + /* Does namelen bytes of name exactly match the symbol? */ static bool sym_is(const char *name, unsigned namelen, const char *symbol) { @@ -1575,6 +1584,7 @@ static const struct devtable devtable[] =3D { {"ishtp", SIZE_ishtp_device_id, do_ishtp_entry}, {"cdx", SIZE_cdx_device_id, do_cdx_entry}, {"vchiq", SIZE_vchiq_device_id, do_vchiq_entry}, + {"coreboot", SIZE_coreboot_device_id, do_coreboot_entry}, }; =20 /* Create MODULE_ALIAS() statements. --=20 2.43.0 From nobody Thu Dec 25 17:55:46 2025 Received: from madrid.collaboradmins.com (madrid.collaboradmins.com [46.235.227.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0ECE06BB50 for ; Fri, 12 Jan 2024 13:21:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="VT/FEgjx" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1705065684; bh=vv7XfyY64AL9x6v0k9WhuSkPS+mvCU15xYmyHxujMQ0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=VT/FEgjxDcYivmSqj8BoJVzPD5kxRg3ansgj2EbmqAD3msqLK6hO1SEOG/XLLVY2i luv8RlWniiUjMey+Gofv04EFijpja4SxG1yJR948rtauLCVfo04QxVG8SDa/KkBdbQ 7psziR/FGNHjLvDtlBx4xNsktEGeoI/hw3sydU6ytcbrzBTTjX8DBFOlTgdcA3qTEu JcPF3qlFd5AEHe+BJ7BDsx2pNfNLn8gYXWDAV9sKVLBxsXbxBiqT7VJCB9NTn8CvIS ADPihfelHE6NiXgWgbfDTu6KXslilFEzU7uktZJ9wcpKpV4VRFCHEv3zTwYhWf4KIv KsMLtKnvqG73g== Received: from localhost.localdomain (zone.collabora.co.uk [167.235.23.81]) (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) (No client certificate requested) (Authenticated sender: nfraprado) by madrid.collaboradmins.com (Postfix) with ESMTPSA id 8BB743781FE5; Fri, 12 Jan 2024 13:21:21 +0000 (UTC) From: =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= To: Tzung-Bi Shih Cc: kernel@collabora.com, AngeloGioacchino Del Regno , chrome-platform@lists.linux.dev, =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= , Brian Norris , Julius Werner , linux-kernel@vger.kernel.org Subject: [PATCH v2 3/7] firmware: google: cbmem: Add to module device table Date: Fri, 12 Jan 2024 10:18:32 -0300 Message-ID: <20240112131857.900734-4-nfraprado@collabora.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240112131857.900734-1-nfraprado@collabora.com> References: <20240112131857.900734-1-nfraprado@collabora.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Create an id table and add it to the module device table to allow the cbmem driver to be automatically loaded when a matching device is found. Acked-by: Brian Norris Signed-off-by: N=C3=ADcolas F. R. A. Prado Reviewed-by: AngeloGioacchino Del Regno --- (no changes since v1) drivers/firmware/google/cbmem.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/firmware/google/cbmem.c b/drivers/firmware/google/cbme= m.c index 88e587ba1e0d..ceb89b4cdbe0 100644 --- a/drivers/firmware/google/cbmem.c +++ b/drivers/firmware/google/cbmem.c @@ -13,6 +13,7 @@ #include #include #include +#include #include #include #include @@ -114,6 +115,12 @@ static int cbmem_entry_probe(struct coreboot_device *d= ev) return 0; } =20 +static const struct coreboot_device_id cbmem_ids[] =3D { + { .tag =3D LB_TAG_CBMEM_ENTRY }, + { /* sentinel */ } +}; +MODULE_DEVICE_TABLE(coreboot, cbmem_ids); + static struct coreboot_driver cbmem_entry_driver =3D { .probe =3D cbmem_entry_probe, .drv =3D { --=20 2.43.0 From nobody Thu Dec 25 17:55:46 2025 Received: from madrid.collaboradmins.com (madrid.collaboradmins.com [46.235.227.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9FE746DCEA for ; Fri, 12 Jan 2024 13:21:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="eBucHIo9" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1705065688; bh=5Zlhk9FViXuszWd2wU0HPdwd/advjvRNhG7guG3jd6Y=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=eBucHIo9anWE6EJwEzY9Q7buyISHqVTcdyY6Ok13pHm51PVG4FgDJpcMxuikzivgO sD2i1iVIuQMoKKLUw6Ww5AQNt68xWYyZ7H/sX0+U2W9LKoNIyQYOkHY/BbfWwtg0va 45sCbBiP3MLvHnpn/Fa/3ZZOez1XgnfXdaJG4RX6/sOZtUFCYfU49p1b1AptFf8N6+ 4Vy46pbklk3nhy9t3aCVJ56VJ1wmPM7ygG9VE0E/J4eZ6Qad9pxg/5j0KZZrEkvgFH xay+P+4p+XupZ3u/OUFy0VdvvPp4qihJyJp+RXtbY/KbkzksZa0Ez/lqg/jaTYd+ZN qSzMTRNIfA6Hw== Received: from localhost.localdomain (zone.collabora.co.uk [167.235.23.81]) (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) (No client certificate requested) (Authenticated sender: nfraprado) by madrid.collaboradmins.com (Postfix) with ESMTPSA id 5CD503782031; Fri, 12 Jan 2024 13:21:25 +0000 (UTC) From: =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= To: Tzung-Bi Shih Cc: kernel@collabora.com, AngeloGioacchino Del Regno , chrome-platform@lists.linux.dev, =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= , Brian Norris , Julius Werner , linux-kernel@vger.kernel.org Subject: [PATCH v2 4/7] firmware: google: vpd: Add to module device table Date: Fri, 12 Jan 2024 10:18:33 -0300 Message-ID: <20240112131857.900734-5-nfraprado@collabora.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240112131857.900734-1-nfraprado@collabora.com> References: <20240112131857.900734-1-nfraprado@collabora.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Create an id table and add it to the module device table to allow the vpd driver to be automatically loaded when a matching device is found. Suggested-by: Brian Norris Signed-off-by: N=C3=ADcolas F. R. A. Prado Reviewed-by: AngeloGioacchino Del Regno --- Changes in v2: - Added this commit drivers/firmware/google/vpd.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/firmware/google/vpd.c b/drivers/firmware/google/vpd.c index ee6e08c0592b..9e9fe9ca1920 100644 --- a/drivers/firmware/google/vpd.c +++ b/drivers/firmware/google/vpd.c @@ -14,6 +14,7 @@ #include #include #include +#include #include #include #include @@ -306,6 +307,12 @@ static void vpd_remove(struct coreboot_device *dev) kobject_put(vpd_kobj); } =20 +static const struct coreboot_device_id vpd_ids[] =3D { + { .tag =3D CB_TAG_VPD }, + { /* sentinel */ } +}; +MODULE_DEVICE_TABLE(coreboot, vpd_ids); + static struct coreboot_driver vpd_driver =3D { .probe =3D vpd_probe, .remove =3D vpd_remove, --=20 2.43.0 From nobody Thu Dec 25 17:55:46 2025 Received: from madrid.collaboradmins.com (madrid.collaboradmins.com [46.235.227.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6E9D06E2A4 for ; Fri, 12 Jan 2024 13:21:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="iVk9KxSs" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1705065692; bh=BLXPKaAyUYO+6jqUrFyRS5lwMciTPldwcRsUMbzDyc8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=iVk9KxSsQtvtgQz99f/zijk6igWk9tf4efY5mWTJjXTiEETjQMS13rTN3ln0twZVs 4/ezaRE8z4zx+YEt0EydLp9Ej7iv6+W/ruOnP+vXE95sNb3aoDXzehdHBTLeQaLMEa xqN7Erkn3v7tljPsnPRAu7m6PH/aVICOjQIDlpmgD8vjtEOdwCbLyaY5Dyt0EK+7/z lmLV54ySEsj2ar2+JxWaKXo63IxX+otyt3Vdg99T7s91XngUE7kcikhVHJmufzbD3A q/7jX2eiLbo/g88JZgTvLfcNcROHF4TCwAyi1/KYiPBTt0mB7BJzgo27vU9bKRcpIT CkMdrSxCA8zww== Received: from localhost.localdomain (zone.collabora.co.uk [167.235.23.81]) (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) (No client certificate requested) (Authenticated sender: nfraprado) by madrid.collaboradmins.com (Postfix) with ESMTPSA id E69583781FE5; Fri, 12 Jan 2024 13:21:28 +0000 (UTC) From: =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= To: Tzung-Bi Shih Cc: kernel@collabora.com, AngeloGioacchino Del Regno , chrome-platform@lists.linux.dev, =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= , Brian Norris , Julius Werner , linux-kernel@vger.kernel.org Subject: [PATCH v2 5/7] firmware: google: memconsole: Add to module device table Date: Fri, 12 Jan 2024 10:18:34 -0300 Message-ID: <20240112131857.900734-6-nfraprado@collabora.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240112131857.900734-1-nfraprado@collabora.com> References: <20240112131857.900734-1-nfraprado@collabora.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Create an id table and add it to the module device table to allow the memconsole driver to be automatically loaded when a matching device is found. Suggested-by: Brian Norris Signed-off-by: N=C3=ADcolas F. R. A. Prado Reviewed-by: AngeloGioacchino Del Regno --- Changes in v2: - Added this commit drivers/firmware/google/memconsole-coreboot.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/firmware/google/memconsole-coreboot.c b/drivers/firmwa= re/google/memconsole-coreboot.c index 74b5286518ee..b8e65b9d8cc0 100644 --- a/drivers/firmware/google/memconsole-coreboot.c +++ b/drivers/firmware/google/memconsole-coreboot.c @@ -11,6 +11,7 @@ #include #include #include +#include =20 #include "memconsole.h" #include "coreboot_table.h" @@ -96,6 +97,12 @@ static void memconsole_remove(struct coreboot_device *de= v) memconsole_exit(); } =20 +static const struct coreboot_device_id memconsole_ids[] =3D { + { .tag =3D CB_TAG_CBMEM_CONSOLE }, + { /* sentinel */ } +}; +MODULE_DEVICE_TABLE(coreboot, memconsole_ids); + static struct coreboot_driver memconsole_driver =3D { .probe =3D memconsole_probe, .remove =3D memconsole_remove, --=20 2.43.0 From nobody Thu Dec 25 17:55:46 2025 Received: from madrid.collaboradmins.com (madrid.collaboradmins.com [46.235.227.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 11DF46E2B2 for ; Fri, 12 Jan 2024 13:21:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="u598Lenm" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1705065695; bh=gIUn32GOZvNsfDJEtW4SBOOpxVUI+08upkQ6PKTzhZg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=u598Lenmeb95HeOuDOhyRzOU/puSD8AwcBF+nzTySLpZZfVZIyNSfSFyfacdwN5kW +v7989vDBjlU+0+mV70V6iFqOe3gPw1PqTbw5QzIaD9wdphdgjIfvP0pcx2yuOQTou 3SWcQhKs1cO4VYTup+KRxUzIXK8HTuo0WMcy2Xyh4uoyFABPSYu1es328E5vd7MhXy lFKa1xIwV4gD6Ipe0aPMMmZy+Os3oj5f6rOjA8dS0eacDP1/dc110lAGriyyGjUevP HsRFpr3f/wXn778wFrMQy3zmVPlNQmM6rads4iJua6odIt1diE3A7rViX5W25FdVOX 6GGR/nJlOLPOw== Received: from localhost.localdomain (zone.collabora.co.uk [167.235.23.81]) (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) (No client certificate requested) (Authenticated sender: nfraprado) by madrid.collaboradmins.com (Postfix) with ESMTPSA id CBCF43782031; Fri, 12 Jan 2024 13:21:32 +0000 (UTC) From: =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= To: Tzung-Bi Shih Cc: kernel@collabora.com, AngeloGioacchino Del Regno , chrome-platform@lists.linux.dev, =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= , Brian Norris , Julius Werner , linux-kernel@vger.kernel.org Subject: [PATCH v2 6/7] firmware: google: framebuffer: Add to module device table Date: Fri, 12 Jan 2024 10:18:35 -0300 Message-ID: <20240112131857.900734-7-nfraprado@collabora.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240112131857.900734-1-nfraprado@collabora.com> References: <20240112131857.900734-1-nfraprado@collabora.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Create an id table and add it to the module device table to allow the framebuffer driver to be automatically loaded when a matching device is found. Suggested-by: Brian Norris Signed-off-by: N=C3=ADcolas F. R. A. Prado Reviewed-by: AngeloGioacchino Del Regno --- Changes in v2: - Added this commit drivers/firmware/google/framebuffer-coreboot.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/firmware/google/framebuffer-coreboot.c b/drivers/firmw= are/google/framebuffer-coreboot.c index 5c84bbebfef8..b33e9c6f97d7 100644 --- a/drivers/firmware/google/framebuffer-coreboot.c +++ b/drivers/firmware/google/framebuffer-coreboot.c @@ -13,6 +13,7 @@ #include #include #include +#include #include #include =20 @@ -80,6 +81,12 @@ static void framebuffer_remove(struct coreboot_device *d= ev) platform_device_unregister(pdev); } =20 +static const struct coreboot_device_id framebuffer_ids[] =3D { + { .tag =3D CB_TAG_FRAMEBUFFER }, + { /* sentinel */ } +}; +MODULE_DEVICE_TABLE(coreboot, framebuffer_ids); + static struct coreboot_driver framebuffer_driver =3D { .probe =3D framebuffer_probe, .remove =3D framebuffer_remove, --=20 2.43.0 From nobody Thu Dec 25 17:55:46 2025 Received: from madrid.collaboradmins.com (madrid.collaboradmins.com [46.235.227.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 21CD96E2D1 for ; Fri, 12 Jan 2024 13:21:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="s1sYTm6l" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1705065701; bh=FzrVgnbK0n6uYdCumXFsahNGrfl5vwlqsMbeKRKrufA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=s1sYTm6liVXdRWh8JDkAX5Lk0MZSbaArK3AfqrMebCSsN7CcXUgITWBxJWKj8IqwR pK5fBkjY3InlhtiDGaIO2AqiOUAXJ1G/cvXU9qOxd0VLoZGggKyLGBjOl3p4PQPft+ Fst3Ra9KsZDEscU0bTiQyokFwwkbuWBbsQByObJLErxlGYMYDSz/4qyObiy1JJHo+I hxclylwIBqHa18mvRV4X7IwLsUvSFuE7hZqhhfCL1RdOe+DjCB79X3AWJA1lspt5XJ M0zZ+0BDygD6qUIn2x5lm68AfQqyFb/m2m3YzH5m1hbJbS66J/gU4IOXhLRySnZBE1 gjO3pzpQaryWw== Received: from localhost.localdomain (zone.collabora.co.uk [167.235.23.81]) (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) (No client certificate requested) (Authenticated sender: nfraprado) by madrid.collaboradmins.com (Postfix) with ESMTPSA id 661783781FE5; Fri, 12 Jan 2024 13:21:36 +0000 (UTC) From: =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= To: Tzung-Bi Shih Cc: kernel@collabora.com, AngeloGioacchino Del Regno , chrome-platform@lists.linux.dev, =?UTF-8?q?N=C3=ADcolas=20F=2E=20R=2E=20A=2E=20Prado?= , Arnd Bergmann , Bjorn Andersson , Catalin Marinas , Geert Uytterhoeven , Konrad Dybcio , Krzysztof Kozlowski , Marek Szyprowski , Neil Armstrong , Will Deacon , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 7/7] arm64: defconfig: Enable support for cbmem entries in the coreboot table Date: Fri, 12 Jan 2024 10:18:36 -0300 Message-ID: <20240112131857.900734-8-nfraprado@collabora.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240112131857.900734-1-nfraprado@collabora.com> References: <20240112131857.900734-1-nfraprado@collabora.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Enable the cbmem driver and dependencies in order to support reading cbmem entries from the coreboot table, which are used to store logs from coreboot on arm64 Chromebooks, and provide useful information for debugging the boot process on those devices. Signed-off-by: N=C3=ADcolas F. R. A. Prado Reviewed-by: AngeloGioacchino Del Regno --- (no changes since v1) arch/arm64/configs/defconfig | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig index 0b0ef6877a12..cd94d55b23b2 100644 --- a/arch/arm64/configs/defconfig +++ b/arch/arm64/configs/defconfig @@ -255,6 +255,9 @@ CONFIG_INTEL_STRATIX10_RSU=3Dm CONFIG_MTK_ADSP_IPC=3Dm CONFIG_QCOM_QSEECOM=3Dy CONFIG_QCOM_QSEECOM_UEFISECAPP=3Dy +CONFIG_GOOGLE_FIRMWARE=3Dy +CONFIG_GOOGLE_CBMEM=3Dm +CONFIG_GOOGLE_COREBOOT_TABLE=3Dm CONFIG_EFI_CAPSULE_LOADER=3Dy CONFIG_IMX_SCU=3Dy CONFIG_IMX_SCU_PD=3Dy --=20 2.43.0