From patchwork Mon Feb 12 14:50:05 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= X-Patchwork-Id: 199864 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:50ea:b0:106:860b:bbdd with SMTP id r10csp2474716dyd; Mon, 12 Feb 2024 06:51:59 -0800 (PST) X-Google-Smtp-Source: AGHT+IHTB9WdiSSjsBeAqTLlAIW5NLW3EM0U99IlXOvnOypXVh96bthFFwgx9X2DZglalLBLA5PY X-Received: by 2002:a17:907:7e83:b0:a3b:ca3a:128c with SMTP id qb3-20020a1709077e8300b00a3bca3a128cmr10174200ejc.22.1707749519468; Mon, 12 Feb 2024 06:51:59 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707749519; cv=pass; d=google.com; s=arc-20160816; b=JZ6T4BfekJvzFgWIN+pM05YYkTSQpWW3iPHQ0IwW+tohX3fNeL62dvuFKNkN8TCPLm 5ykugC/darARIQF2rI9s0yTsLk9rJQexXQgo9qTkem95XJpdooPkh9s1f0L+Oci3aeBK 1eF40GeSA2AvKirjYYnWX1qoAghZYQRbDdoOfoLdMuNh9fcali8XAxKxiJKKqpbxJCLy NxEQ80ewOeTpucsLN4wu1eiVQyaIyC/KFVajaFt1qbzCEqA+SacgTCnhjIlzj9V0lVhI SCOvja2ZC1KEd8zq+JpfKumSWxpGwo8s7idCVHPKv+YYpPE8J/WMhBJ1QEGTcGr78pyb 3jBw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=h/x/3y1n/LIJrYQs7R5jPDtBYiOho5M7BtfSUmdM2qU=; fh=H2WJ/tNgLiEMww3V0N5/jxvXCXpPJMjXZbK2aXel9C0=; b=UPWEaiJCb4yk3A2R79HCCqhWr+3DNJJODrrtgJEnw/QBC+dUOVXoRmBZWtkHuGmOUW xkxt5QGRSGa99A9B466XwH0BY9SnZWE6ROf6L3uWmw5NLSciLlBEGT0N75cX+IY8OAqO xpei5+TeVxstodslweT6C0v9KVM0aYZtjMws6TiCfwA51iSw0WUY0Cn3CKKLy5q3DPBU 2za6HkbT7j2SHYTiFJAd93uEFO4Ckik8hdmgoNR/FMHFV3wygpunN2o8e6UdXy2apWPe CCuOAN62y9QcxPq6zBzZC3avPNK41GMM7hBk+mk8wioOLuROtE2SBPLZrmUT2TLM/yFY RBSA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=u3EpcVKE; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-61841-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-61841-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com X-Forwarded-Encrypted: i=2; AJvYcCVPeT7fSxD9uBv/xmIXaiHIw+NEDDpWhPROmmSACufv8CmauWsqjtcTR9zKXrNuevA4l67LoSLxuBYp4iZpwTsAEN3dJQ== Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id f19-20020a1709067f9300b00a384f7dac1asi268255ejr.78.2024.02.12.06.51.59 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Feb 2024 06:51:59 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-61841-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=u3EpcVKE; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-61841-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-61841-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 234581F22A7D for ; Mon, 12 Feb 2024 14:51:56 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A5EB73C491; Mon, 12 Feb 2024 14:51:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="u3EpcVKE" 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 723983BB34; Mon, 12 Feb 2024 14:51:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=46.235.227.194 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707749486; cv=none; b=iyiPFVLAfm4i/vTJYhgYNx7srWLvNnr8nMVFPIbsKzjhgkD3ML8BimqHFtdOpulPr7nR2VO+Cye1ZdYU0FsaZfSnDUBL4ss5v3xkq7iq/NtebhhcUsPo7MIJfdR7cuAIpibOSqbMKCjUIpevpJSknBrRGD/cVRFYWW7JqzRQePc= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707749486; c=relaxed/simple; bh=OiujR5lhNKhEimBkSB+EFRf6rM0jXBiQhXbfsxIV9UE=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Axr3lIZZoUARrUmDPsZ8DoiUMmMIir94rlfbJJeziPBMLOZiUFQn7kyO+r8HOFWqjS+qlEuLXWaavOIG4T9K4O37UOhW5ZZR19A3HqItArnSa2/foANO+mgeK3hqBkEwelvsVouMyI5etZ6uwOhAUpxKW2MDCA0NPG8Mh7cYgHI= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com; spf=pass smtp.mailfrom=collabora.com; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b=u3EpcVKE; arc=none smtp.client-ip=46.235.227.194 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 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1707749482; bh=OiujR5lhNKhEimBkSB+EFRf6rM0jXBiQhXbfsxIV9UE=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=u3EpcVKEmcqpDIx/5waMjmUKIUIl0Boy2XqZqUi01fAXxocc0wSx+sXm6HN4uQy5/ sXZITsUKLcGkbFg5ity4LvFazzYGWMSogdiQdLFlO7+Bb0DhGbHZxNgyh/1fRQD/kZ rGjpPm8YYdNYAFPXd7seJX1G1YCVx4UYgjZuwDjVDwqsStncmt+/yMI3+DdnJA/3e2 Q13eGoqmTLdyHKgjLRdqJ+0ariP7aibUNHU2ZqdNJcEOzJwWwY54atV0+wFfmLsiHW XjRjl6RnKlhtRCTpQsQ5CV4J+t+8nGG/Nr/qZRkauyG1rdZ5OkN1PJNwR4O2sp4nJ0 6suxZhvZcRxvQ== Received: from [192.168.1.30] (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 9C5FD37810EF; Mon, 12 Feb 2024 14:51:19 +0000 (UTC) From: =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= Date: Mon, 12 Feb 2024 09:50:05 -0500 Subject: [PATCH v4 1/4] firmware: coreboot: Generate modalias uevent for devices Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240212-coreboot-mod-defconfig-v4-1-d14172676f6d@collabora.com> References: <20240212-coreboot-mod-defconfig-v4-0-d14172676f6d@collabora.com> In-Reply-To: <20240212-coreboot-mod-defconfig-v4-0-d14172676f6d@collabora.com> To: Tzung-Bi Shih Cc: Arnd Bergmann , Brian Norris , Julius Werner , Masahiro Yamada , Nathan Chancellor , Nicolas Schier , Catalin Marinas , Will Deacon , AngeloGioacchino Del Regno , Andy Shevchenko , Greg Kroah-Hartman , kernel@collabora.com, chrome-platform@lists.linux.dev, linux-kernel@vger.kernel.org, linux-kbuild@vger.kernel.org, linux-arm-kernel@lists.infradead.org, =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= X-Mailer: b4 0.12.4 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790705160479949774 X-GMAIL-MSGID: 1790705160479949774 Generate a modalias uevent for devices in the coreboot bus to allow userspace to automatically load the corresponding modules. Acked-by: Brian Norris Reviewed-by: AngeloGioacchino Del Regno Reviewed-by: Brian Norris Signed-off-by: Nícolas F. R. A. Prado --- drivers/firmware/google/coreboot_table.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/drivers/firmware/google/coreboot_table.c b/drivers/firmware/google/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); } +static int coreboot_bus_uevent(const struct device *dev, struct kobj_uevent_env *env) +{ + struct coreboot_device *device = CB_DEV(dev); + u32 tag = device->entry.tag; + + return add_uevent_var(env, "MODALIAS=coreboot:t%08X", tag); +} + static struct bus_type coreboot_bus_type = { .name = "coreboot", .match = coreboot_bus_match, .probe = coreboot_bus_probe, .remove = coreboot_bus_remove, + .uevent = coreboot_bus_uevent, }; static void coreboot_device_release(struct device *dev) From patchwork Mon Feb 12 14:50:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= X-Patchwork-Id: 199865 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:50ea:b0:106:860b:bbdd with SMTP id r10csp2474780dyd; Mon, 12 Feb 2024 06:52:10 -0800 (PST) X-Google-Smtp-Source: AGHT+IGG9uXJQhzLzhpyu/i7MFRhB1jq8lUBY14x64j4W8HTYNynIyuO7u86JTfbxTBGbVCPfLVi X-Received: by 2002:a2e:9088:0:b0:2d0:d967:b12a with SMTP id l8-20020a2e9088000000b002d0d967b12amr4553330ljg.51.1707749530772; Mon, 12 Feb 2024 06:52:10 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707749530; cv=pass; d=google.com; s=arc-20160816; b=u2xjRU8T+4SZlIBZVKDK/BIq0dn/cZe+1wjybM1Wq+W5nCbszl2S6keDdrUJcGgWiS komq4D0OFy1wryqbCICAQ48Jxsy1FIToM9cl2i+5gWcf7DspG9iY81i+IxxKjkeEnTX7 STdb+lkX3eI9JHnJxvWPOHopqekUJWBVFxcLmfTQVF1WetRgYCeYQxH73XTNjoFzSuJw uQwQSkpDo/oeckDgvJLPLhn+yTrlwXV0laR6qGydWPmNZbM6zXLnfC7+S51yO1yh3IYt fHkXdrrXZSZesn4QpSSGrjuRUnp23c2bxxiUdUn9Syun+OON4rzKG+JALZqZ5qRxzisB uhLA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=4AwWffQa2thzVPKbPp5UEVZdDdiw5+4KTks8raVSz0U=; fh=YqQSpH2RGGORgXDgbZOJEYeh2lRL1q2+fJNBBQWH3Ow=; b=VKxdFNiHH9mnfFifhGdGfL6vrdEVFtUIy4WAyGOU7u8CulWPjcve9xhDfPARpifUrj qOoV7+wj6rjwpAAltaz+FVjkkFQMOBtlmF0Nmwrq7JMPNAWPqu2dxEaMSawLKf+JvbTT Hi4GMmEfNru1V7GU8dq6duweJg0i68p3TUZV8/MxKrFnuXPamq9hIPOj1nixZ4GHaded eD2CcuH2edRr2XpxpOgw661WusUIlOcNzZYI4O2G5vWYDqimhwpR8OnEZlJeQ46RGvZA Bii8QRxcRcL+BqMTtOVq4K8ck0HJCvWdbl9VM1KU3qujJUP2r1yyZmcjyRtz66WNbkWD Lzuw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=GX8DLeUc; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-61842-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-61842-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com X-Forwarded-Encrypted: i=2; AJvYcCXCLB3NdsLJh29mXMobWEPtzcL0hHiL1G3onktkBkYcOjMxR20Eqrg7OMIXJE2YxXXrtcR1EqWU8k04HJMHUa0TmG00TA== Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id v15-20020a056402184f00b005601a6e6cd4si2660181edy.655.2024.02.12.06.52.10 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Feb 2024 06:52:10 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-61842-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=GX8DLeUc; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-61842-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-61842-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 2F78D1F21F39 for ; Mon, 12 Feb 2024 14:52:10 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C770E3BB25; Mon, 12 Feb 2024 14:51:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="GX8DLeUc" 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 9204D3C488; Mon, 12 Feb 2024 14:51:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=46.235.227.194 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707749489; cv=none; b=OFr6EgkS0m48zTTWHaYVLHJLmeFa6Xr0jthd230hhpfGLPURKLJq5XJgnMCFy25V+Tf+wD6RQBTTHS/h/A/oKwosNWo5SEINJpXzhL0pWB2vPBilmQw/auZuLRvHbDJfdTHcHhIjt0UHvvOvj3eicJ26KPqv4luP7TydZMAqhc0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707749489; c=relaxed/simple; bh=1TCvFrGXA9WRNIGq5qiS6fBnB/8Sfm3xS2xnBDJoK28=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=VEyZlOqY6LnfiEAxFKIIw2IAXltlCuQ6x/66nqIfk0TuM0HVe588Z1V6TdY8Qbses8cLaoYr/ChJ+OTnYRukPBYqYIXVZ5XtF1NLoEJc7UCKNdhMOw0Y12jBc/NmcSxVOtyhnIc5RPsIWJ7N69bUnELVGyKQUBq0N+EZZiZMmEE= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com; spf=pass smtp.mailfrom=collabora.com; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b=GX8DLeUc; arc=none smtp.client-ip=46.235.227.194 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 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1707749486; bh=1TCvFrGXA9WRNIGq5qiS6fBnB/8Sfm3xS2xnBDJoK28=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=GX8DLeUcsHn718WGmcEX+K25/QWmMhkgZHgz5FKPw2HfaP9wTwEFGpGbXFQZsSJ4E dY2G11h816hu9Bo86/VdQWeFvWL7C9l4uk4sHfobftI68YLgqph1qUwOhCEVdw837w 7ugfshFFKYdaRfe/1P6yEwDcMe577HoMELj9FLcsy4kjI4yFHkuwRCjpEU/BhRRpEA Sdm0AAnmsSKjKmU7UaFydCBPm990kV70cA8irr2WS2BaIJMAVrIxIGV+sHwMSeZRmO Tqp7anmsAXg6MRzc3wkFwJ5NwQsq4WF21o9mCgcBSRM5kdStPaIpGNPn7+NtIkPvXd IDtAo4++BWVhA== Received: from [192.168.1.30] (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 2FE39378203F; Mon, 12 Feb 2024 14:51:23 +0000 (UTC) From: =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= Date: Mon, 12 Feb 2024 09:50:06 -0500 Subject: [PATCH v4 2/4] firmware: coreboot: Generate aliases for coreboot modules Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240212-coreboot-mod-defconfig-v4-2-d14172676f6d@collabora.com> References: <20240212-coreboot-mod-defconfig-v4-0-d14172676f6d@collabora.com> In-Reply-To: <20240212-coreboot-mod-defconfig-v4-0-d14172676f6d@collabora.com> To: Tzung-Bi Shih Cc: Arnd Bergmann , Brian Norris , Julius Werner , Masahiro Yamada , Nathan Chancellor , Nicolas Schier , Catalin Marinas , Will Deacon , AngeloGioacchino Del Regno , Andy Shevchenko , Greg Kroah-Hartman , kernel@collabora.com, chrome-platform@lists.linux.dev, linux-kernel@vger.kernel.org, linux-kbuild@vger.kernel.org, linux-arm-kernel@lists.infradead.org, =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= X-Mailer: b4 0.12.4 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790705171939742171 X-GMAIL-MSGID: 1790705171939742171 Generate aliases for coreboot modules to allow automatic module probing. Reviewed-by: AngeloGioacchino Del Regno Reviewed-by: Brian Norris Signed-off-by: Nícolas F. R. A. Prado Acked-by: Masahiro Yamada --- include/linux/mod_devicetable.h | 10 ++++++++++ scripts/mod/devicetable-offsets.c | 3 +++ scripts/mod/file2alias.c | 10 ++++++++++ 3 files changed, 23 insertions(+) diff --git a/include/linux/mod_devicetable.h b/include/linux/mod_devicetable.h index f458469c5ce5..7a9a07ea451b 100644 --- a/include/linux/mod_devicetable.h +++ b/include/linux/mod_devicetable.h @@ -960,4 +960,14 @@ struct vchiq_device_id { char name[32]; }; +/** + * struct coreboot_device_id - Identifies a coreboot table entry + * @tag: tag ID + * @driver_data: driver specific data + */ +struct coreboot_device_id { + __u32 tag; + kernel_ulong_t driver_data; +}; + #endif /* LINUX_MOD_DEVICETABLE_H */ diff --git a/scripts/mod/devicetable-offsets.c b/scripts/mod/devicetable-offsets.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); + 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; } +/* Looks like: coreboot:tN */ +static int do_coreboot_entry(const char *filename, void *symval, char *alias) +{ + 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[] = { {"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}, }; /* Create MODULE_ALIAS() statements. From patchwork Mon Feb 12 14:50:07 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= X-Patchwork-Id: 199866 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:50ea:b0:106:860b:bbdd with SMTP id r10csp2474952dyd; Mon, 12 Feb 2024 06:52:32 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCU4eq/IHmBSB/Kv/BaETZSedhiGTyHPJZFALJ1uFTFUqxXlCz9nVtKDR7mllZ9kJRMD1OY7EqAOhTfQQb9WOkyVsWOb8A== X-Google-Smtp-Source: AGHT+IGHNyqtERCS9VGAcxmBWGfH5pjV6fNP0YOJpnFDZMrQHnJOMqhfoKNFqW9E9X/izUs/nZiP X-Received: by 2002:a05:6870:e315:b0:219:a832:bc4c with SMTP id z21-20020a056870e31500b00219a832bc4cmr6626264oad.9.1707749552789; Mon, 12 Feb 2024 06:52:32 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707749552; cv=pass; d=google.com; s=arc-20160816; b=tAqLBVFPkl3euUdH97ct/JKMAysgQdVqaCHPcwK9crsN/vDFYJwzN6Lxsen4AOzVZp 0M86rjs3JJoqYtLBMKEmDCbQawIYVW/rqC414SCvsfuJ05BiHWvawYp/cJ8alqf8y6hr DOqSlNcxFuV4oxVS3NDD5G3MpViji4nK9qS3hI84BJHfqZFwGc6fnSJUkEONDjEQjUhV yu8oi2M8wGk8ro8p40OIfYp/fXxHvrjrZg1J9bsB/Y+kDSLMmYiprW15gYzoE+K502eU es3zogu1MmL3JFvRylZoMDfO+kyryDFo+7KyR7axmdz8LykFNgFKAJbu3gIAhdF7gv5a 6E0w== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=VNkcLUsYsZepi/AgglHtLiJbkWtWzJaWO1Vo5CqQYt4=; fh=kvoPr1j4fTEPgbUs6Nqfx1rxEdxkIJCMXDxKGmX0BFY=; b=ECUI1Y2YefYu9luZM1d3may3CqOfGCkjJRbWzcaD1perclF7X0cc6SNy3h/fstopAM X26H1QV9TwCaSE087PvQze06fYjtLHXc2YzEmMDxaJfUHI/501Qp9wfqKxuv7xPNDUFT 0WBY0HN0hYNLGBov2FtMHmh2DoWvOYzLDQf/4za0xrqRETNSspF6hbi4PGGCQcSxaq23 qY09iQXNbfUWSfFJzyyEwxWnqTuG2JI1lbY51P6WN/g039zs68Dq70rJg0DOHj8IG++u yOzR97c9F6AldGIpG3KNXCtPU1snX6kIJaHAjFaRgFBApFzM7d1Rkgt2iCkL/vfokYwH oxfw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=jCh3ZlbA; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-61843-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-61843-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com X-Forwarded-Encrypted: i=2; AJvYcCUBdLAEcZNfwVA3xg0hScw+NMhE9l9qPaXWsvdY5Zc9kjLKelRRoGilj2rDN4bUmUS5xObjmq3h1LSh/jRGvxgtWphq5w== Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id g24-20020ac84818000000b0042a99face24si474767qtq.795.2024.02.12.06.52.32 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Feb 2024 06:52:32 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-61843-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=jCh3ZlbA; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-61843-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-61843-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 835C61C2116B for ; Mon, 12 Feb 2024 14:52:32 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 05D493D0AB; Mon, 12 Feb 2024 14:51:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="jCh3ZlbA" 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 32A193CF40; Mon, 12 Feb 2024 14:51:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=46.235.227.194 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707749493; cv=none; b=kd27ijvdO//p/m+GTpzhpFiofBkMpwY/TCHpr3LhKhQQBfBpiGJcDwi/9GrhNmjqX+Jko7ywyOqT6bgk/0vp8g3GRHYScwjjpuXHz6XyELztbodcNU/0SOA/EJUla85qRwhxrYBE7bSRvTLOx/CtUIf20WcHinBUw2NCnyLZXiI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707749493; c=relaxed/simple; bh=2YazRus17kIzAJnZt/Xcx5DkIWkxOxNttVVGwgfNxTY=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=JXX3k2ww6r6PE0cscsPGKzFCcmddml8ZpnYkp5lNIWmnZZMUBhDy9J7vx1pWUVsRtHGXP+DYBquDsFlD2fq4+Nl4BQOGDnMLXWwP/RDKYsjbyg+0ZPUTwl1ketHu/Q7BBYtQmtKl8V3eRoBgqA9L93gw3IH/PZxdb2XBsG7Pb3Y= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com; spf=pass smtp.mailfrom=collabora.com; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b=jCh3ZlbA; arc=none smtp.client-ip=46.235.227.194 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 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1707749489; bh=2YazRus17kIzAJnZt/Xcx5DkIWkxOxNttVVGwgfNxTY=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=jCh3ZlbAWxcEHTFfj5OiAFAso89vXFUCdMfUZqDWIPseDllYp/WgvIN9bATtwLl83 RTCSEem/cOIhHvdMz9aEwFrtEvESaUkg4RKNkvjK+6m+p90ADLFoSjxtCW7h5L3WcC 2x10zi3CWnek0QCaQPNxqBVnsiCB7mxJDb3a1Fayy3JljwWgXaqACLQ4eCwTFnhC6/ 89GyFxcYdEeK+3AueFqyy3Zmg1G3vE5+F2RxWHR03XOLQAmDzkblkb7NyjlsOBB6EX aBNL89HbdtVss8OBJDHpotNii13wkHK2icQER2iXjrgAkUCxyiU3PKR0XFJadyum3g AqgW5hG6lzuLg== Received: from [192.168.1.30] (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 931A33780C22; Mon, 12 Feb 2024 14:51:26 +0000 (UTC) From: =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= Date: Mon, 12 Feb 2024 09:50:07 -0500 Subject: [PATCH v4 3/4] firmware: coreboot: Replace tag with id table in driver struct Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240212-coreboot-mod-defconfig-v4-3-d14172676f6d@collabora.com> References: <20240212-coreboot-mod-defconfig-v4-0-d14172676f6d@collabora.com> In-Reply-To: <20240212-coreboot-mod-defconfig-v4-0-d14172676f6d@collabora.com> To: Tzung-Bi Shih Cc: Arnd Bergmann , Brian Norris , Julius Werner , Masahiro Yamada , Nathan Chancellor , Nicolas Schier , Catalin Marinas , Will Deacon , AngeloGioacchino Del Regno , Andy Shevchenko , Greg Kroah-Hartman , kernel@collabora.com, chrome-platform@lists.linux.dev, linux-kernel@vger.kernel.org, linux-kbuild@vger.kernel.org, linux-arm-kernel@lists.infradead.org, =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= X-Mailer: b4 0.12.4 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790705194960263793 X-GMAIL-MSGID: 1790705194960263793 Switch the plain 'tag' field in struct coreboot_driver for the newly created coreboot_device_id struct, which also contains a tag field and has the benefit of allowing modalias generation, and update all coreboot drivers accordingly. While at it, also add the id table for each driver to the module device table to allow automatically loading the module. Reviewed-by: AngeloGioacchino Del Regno Reviewed-by: Brian Norris Signed-off-by: Nícolas F. R. A. Prado --- drivers/firmware/google/cbmem.c | 8 +++++++- drivers/firmware/google/coreboot_table.c | 11 ++++++++++- drivers/firmware/google/coreboot_table.h | 3 ++- drivers/firmware/google/framebuffer-coreboot.c | 8 +++++++- drivers/firmware/google/memconsole-coreboot.c | 8 +++++++- drivers/firmware/google/vpd.c | 8 +++++++- 6 files changed, 40 insertions(+), 6 deletions(-) diff --git a/drivers/firmware/google/cbmem.c b/drivers/firmware/google/cbmem.c index 88e587ba1e0d..c2bffdc352a3 100644 --- a/drivers/firmware/google/cbmem.c +++ b/drivers/firmware/google/cbmem.c @@ -114,6 +114,12 @@ static int cbmem_entry_probe(struct coreboot_device *dev) return 0; } +static const struct coreboot_device_id cbmem_ids[] = { + { .tag = LB_TAG_CBMEM_ENTRY }, + { /* sentinel */ } +}; +MODULE_DEVICE_TABLE(coreboot, cbmem_ids); + static struct coreboot_driver cbmem_entry_driver = { .probe = cbmem_entry_probe, .drv = { @@ -121,7 +127,7 @@ static struct coreboot_driver cbmem_entry_driver = { .owner = THIS_MODULE, .dev_groups = dev_groups, }, - .tag = LB_TAG_CBMEM_ENTRY, + .id_table = cbmem_ids, }; module_coreboot_driver(cbmem_entry_driver); diff --git a/drivers/firmware/google/coreboot_table.c b/drivers/firmware/google/coreboot_table.c index c1b9a9e8e8ed..33971cf33112 100644 --- a/drivers/firmware/google/coreboot_table.c +++ b/drivers/firmware/google/coreboot_table.c @@ -28,8 +28,17 @@ static int coreboot_bus_match(struct device *dev, struct device_driver *drv) { struct coreboot_device *device = CB_DEV(dev); struct coreboot_driver *driver = CB_DRV(drv); + const struct coreboot_device_id *id; - return device->entry.tag == driver->tag; + if (!driver->id_table) + return 0; + + for (id = driver->id_table; id->tag; id++) { + if (device->entry.tag == id->tag) + return 1; + } + + return 0; } static int coreboot_bus_probe(struct device *dev) diff --git a/drivers/firmware/google/coreboot_table.h b/drivers/firmware/google/coreboot_table.h index d814dca33a08..86427989c57f 100644 --- a/drivers/firmware/google/coreboot_table.h +++ b/drivers/firmware/google/coreboot_table.h @@ -13,6 +13,7 @@ #define __COREBOOT_TABLE_H #include +#include /* Coreboot table header structure */ struct coreboot_table_header { @@ -93,7 +94,7 @@ struct coreboot_driver { int (*probe)(struct coreboot_device *); void (*remove)(struct coreboot_device *); struct device_driver drv; - u32 tag; + const struct coreboot_device_id *id_table; }; /* Register a driver that uses the data from a coreboot table. */ diff --git a/drivers/firmware/google/framebuffer-coreboot.c b/drivers/firmware/google/framebuffer-coreboot.c index 5c84bbebfef8..07c458bf64ec 100644 --- a/drivers/firmware/google/framebuffer-coreboot.c +++ b/drivers/firmware/google/framebuffer-coreboot.c @@ -80,13 +80,19 @@ static void framebuffer_remove(struct coreboot_device *dev) platform_device_unregister(pdev); } +static const struct coreboot_device_id framebuffer_ids[] = { + { .tag = CB_TAG_FRAMEBUFFER }, + { /* sentinel */ } +}; +MODULE_DEVICE_TABLE(coreboot, framebuffer_ids); + static struct coreboot_driver framebuffer_driver = { .probe = framebuffer_probe, .remove = framebuffer_remove, .drv = { .name = "framebuffer", }, - .tag = CB_TAG_FRAMEBUFFER, + .id_table = framebuffer_ids, }; module_coreboot_driver(framebuffer_driver); diff --git a/drivers/firmware/google/memconsole-coreboot.c b/drivers/firmware/google/memconsole-coreboot.c index 74b5286518ee..24c97a70aa80 100644 --- a/drivers/firmware/google/memconsole-coreboot.c +++ b/drivers/firmware/google/memconsole-coreboot.c @@ -96,13 +96,19 @@ static void memconsole_remove(struct coreboot_device *dev) memconsole_exit(); } +static const struct coreboot_device_id memconsole_ids[] = { + { .tag = CB_TAG_CBMEM_CONSOLE }, + { /* sentinel */ } +}; +MODULE_DEVICE_TABLE(coreboot, memconsole_ids); + static struct coreboot_driver memconsole_driver = { .probe = memconsole_probe, .remove = memconsole_remove, .drv = { .name = "memconsole", }, - .tag = CB_TAG_CBMEM_CONSOLE, + .id_table = memconsole_ids, }; module_coreboot_driver(memconsole_driver); diff --git a/drivers/firmware/google/vpd.c b/drivers/firmware/google/vpd.c index ee6e08c0592b..8e4216714b29 100644 --- a/drivers/firmware/google/vpd.c +++ b/drivers/firmware/google/vpd.c @@ -306,13 +306,19 @@ static void vpd_remove(struct coreboot_device *dev) kobject_put(vpd_kobj); } +static const struct coreboot_device_id vpd_ids[] = { + { .tag = CB_TAG_VPD }, + { /* sentinel */ } +}; +MODULE_DEVICE_TABLE(coreboot, vpd_ids); + static struct coreboot_driver vpd_driver = { .probe = vpd_probe, .remove = vpd_remove, .drv = { .name = "vpd", }, - .tag = CB_TAG_VPD, + .id_table = vpd_ids, }; module_coreboot_driver(vpd_driver); From patchwork Mon Feb 12 14:50:08 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= X-Patchwork-Id: 199867 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:50ea:b0:106:860b:bbdd with SMTP id r10csp2475057dyd; Mon, 12 Feb 2024 06:52:42 -0800 (PST) X-Google-Smtp-Source: AGHT+IEhd5XharvyBrjrKLR9bQObbIMaFME1GiyFmXoSpzzbjw2YLVYeCQekUMs58RPHIBDBG1zo X-Received: by 2002:a05:6e02:1d89:b0:363:c796:7736 with SMTP id h9-20020a056e021d8900b00363c7967736mr9805889ila.28.1707749562379; Mon, 12 Feb 2024 06:52:42 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707749562; cv=pass; d=google.com; s=arc-20160816; b=TIanVpKeWPmUQcaObPm5a/ngbTO80l32hbGVE0fjoE6oDh4392/locVrG/QZUYDdZk tWlOUG3D8JL/xCEtnfM+OSSL1x6TIu90O8dJtPoPmNfBGlA0NvFM8bm6Xs72R7yEKZzk ONAU0c3DUriZnWH/9QCkY4C3IyZXU/MCaZeL3PWDJXFk+f+H22rDPTnl2FQrMI/HbXr5 CRiPKYido9ko/kY1GoU/Au6nQE99wtqNCu7e4o6QPlROs0fkaB7HSF/fn8iwQLgUmQC0 AaTiF2e5x6+16b7tO1dzL6PyCMrxTAamFN7Rfl/lE8hd19d0/ndxOE/Lls+o8e2boogU +O4A== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=x79/SB+bskcOgSTqE6Z3y+KhsmEdQixCrp63f0Fnun4=; fh=cC9YZYDEJOPGCSGq3iEBNLl6SnoVJCO/FBpXD29wJDM=; b=ohA2qCKfM1rPcnvxC1XvjbXuw1/SyDkiSgLjvmKDy2ABPl92CWlqi+saq/2ehkP/ZC nUfl1UtB06L9NVX1lmruXGk6HPvBQaKRWZTu15pKGr0Bm19AKnvh6b2BQxoAurFuJo+h JuJjUtQAT1pbuufyOY8KlcdscsVD0nqYk6VUxJ3ni0gSpD/VkX5AWR+wM8OaQD0ROTPf k901zYdtliilNiW6BK+JoClfinWS7B5Fk9jrZdVICZ/Z1VyASmEMIymRGTbMUanq2nUu fshrQNDqAUkZHbkiraZf+xl7gYWopjihpf3386JriBP3gBexUglUc0sufPSHvYROeHt+ QZwQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=QpbkmfCW; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-61844-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-61844-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com X-Forwarded-Encrypted: i=2; AJvYcCWKVSX9u7WqK8O7GqRsvD2yvitVnnl4Fn4axistlD8IXUHQHUMa/MIhKWKuqBptbWbdBGT/CH91cYOamFepwMEwfRdxpQ== Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id e14-20020a65678e000000b005dc352a5637si337578pgr.323.2024.02.12.06.52.42 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Feb 2024 06:52:42 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-61844-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=QpbkmfCW; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-61844-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-61844-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 26F23282357 for ; Mon, 12 Feb 2024 14:52:42 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id BF8683D0C9; Mon, 12 Feb 2024 14:51:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="QpbkmfCW" 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 B60AE3CF57; Mon, 12 Feb 2024 14:51:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=46.235.227.194 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707749496; cv=none; b=d/ZC4vz5AYP9D8i2OY5AlPPeqrgA/njnvQpVgDdUBj0+bndL9OOMoAVmQv84t0KQIm/nqyqcQ65UQ/gF5bnqb77nwKZ44IxVVzCyQHk5jotMxR/rVEzRrgMA20QuuvQbNdTmruJQkMmFRmhvsWmbve4tMtgE4EKX04G5RTySXYg= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707749496; c=relaxed/simple; bh=6X0d2IvNibIl56LRw76KLgL3zAFeQRXW6NnnwscrVLA=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=b5vB39obKsQ2otxsfzabTTwuA3HywxJmvaJayGqaS6yvMK/pHHz/AT0fksXmur2+ExebV63Ja/NDFYjgjnFoBlAaGVtgeMzY5uhZ8d1mRCOdUs1sRI9u8U7/nfsgQ5RMekB28XodjYOHVY177JZKls7xUqKmKO9fH7XI3lXh7Is= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com; spf=pass smtp.mailfrom=collabora.com; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b=QpbkmfCW; arc=none smtp.client-ip=46.235.227.194 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 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1707749493; bh=6X0d2IvNibIl56LRw76KLgL3zAFeQRXW6NnnwscrVLA=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=QpbkmfCWJzIcJfM0t5YGGzIZIf+8Tp7zIuPnPxpHIXbRimZEN5bkVTCVJViIZLp2x A+91vAuKSk3GzDg346OTBFEBRTUax6XL4st40STh1HCPASUdpW9kdEiFKa4hLzbIWT 2ZEGM1E8TIKE5V0JNgLeDyh9tMvRlTh0ZrgTO751IMKKWVCJKYwNQzqUDGx4pxPJgS 1Sj5ZCXKBRlYF16H2xeLnX+2nXHd986ulU46O9H4WfKhoVHQ9fybjRN/V13lz+BlnJ 47mBzu4bsli15XU14/dQrhhNDSCvG/QVJJbUvh5fiHqrXJTlO7tB9mKnvpMbvUBceP hu2u+HSRoP75w== Received: from [192.168.1.30] (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 DC4BF378203F; Mon, 12 Feb 2024 14:51:29 +0000 (UTC) From: =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= Date: Mon, 12 Feb 2024 09:50:08 -0500 Subject: [PATCH v4 4/4] arm64: defconfig: Enable support for cbmem entries in the coreboot table Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <20240212-coreboot-mod-defconfig-v4-4-d14172676f6d@collabora.com> References: <20240212-coreboot-mod-defconfig-v4-0-d14172676f6d@collabora.com> In-Reply-To: <20240212-coreboot-mod-defconfig-v4-0-d14172676f6d@collabora.com> To: Tzung-Bi Shih Cc: Arnd Bergmann , Brian Norris , Julius Werner , Masahiro Yamada , Nathan Chancellor , Nicolas Schier , Catalin Marinas , Will Deacon , AngeloGioacchino Del Regno , Andy Shevchenko , Greg Kroah-Hartman , kernel@collabora.com, chrome-platform@lists.linux.dev, linux-kernel@vger.kernel.org, linux-kbuild@vger.kernel.org, linux-arm-kernel@lists.infradead.org, =?utf-8?b?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= X-Mailer: b4 0.12.4 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790705204665591872 X-GMAIL-MSGID: 1790705204665591872 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. Reviewed-by: AngeloGioacchino Del Regno Reviewed-by: Brian Norris Signed-off-by: Nícolas F. R. A. Prado --- arch/arm64/configs/defconfig | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm64/configs/defconfig b/arch/arm64/configs/defconfig index 361c31b5d064..49121133f045 100644 --- a/arch/arm64/configs/defconfig +++ b/arch/arm64/configs/defconfig @@ -255,6 +255,9 @@ CONFIG_INTEL_STRATIX10_RSU=m CONFIG_MTK_ADSP_IPC=m CONFIG_QCOM_QSEECOM=y CONFIG_QCOM_QSEECOM_UEFISECAPP=y +CONFIG_GOOGLE_FIRMWARE=y +CONFIG_GOOGLE_CBMEM=m +CONFIG_GOOGLE_COREBOOT_TABLE=m CONFIG_EFI_CAPSULE_LOADER=y CONFIG_IMX_SCU=y CONFIG_IMX_SCU_PD=y