From patchwork Mon Jun 17 14:45:19 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Marek_Beh=C3=BAn?= X-Patchwork-Id: 13700861 X-Patchwork-Delegate: arnd@arndb.de Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 18636C27C79 for ; Mon, 17 Jun 2024 14:45:48 +0000 (UTC) Received: by smtp.kernel.org (Postfix) id 03947C4DE03; Mon, 17 Jun 2024 14:45:48 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E13F0C4AF1C; Mon, 17 Jun 2024 14:45:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1718635547; bh=abCGVgPrm6/2lwzY06Zu5nJeF2cfxXJX2oWog4gA1Ns=; h=From:List-Id:To:Cc:Subject:Date:In-Reply-To:References:From; b=T6NTOYSznVWnAafkYdHeGZQN2Pu+DNMc5Qds/xjGUeTn21k1W57qqlajY3i4lzA8X Hlw2AzrjVsc02FDys7EPh2PEnHmJW82wh6c0Edfz9ccgPkJ19+mCudQ59jMqYZNxl2 K/PyHJa23BMkS3Zb4MVfjsrIgJK8wifl6WP9sxivZQZoq0bwjnPpkCD5Sgz2Us0mw1 jOGxmISc2LXKgS2DD2yGAJnGw+OqTbp31SGMX8RX5a4jKqKKowt4ZxUy7LRx4SXJ00 s6NJ68ExTaW/omqhUs/wEnYSeZ4l5calzp8W4FCo+Q+qbn5K9Y6tSb+qXeRixoH4sM J+edAgtwcuyzA== From: =?utf-8?q?Marek_Beh=C3=BAn?= List-Id: To: Gregory CLEMENT , Andrew Lunn , Arnd Bergmann , soc@kernel.org, arm@kernel.org, Andy Shevchenko , Hans de Goede , =?utf-8?q?Ilpo_J=C3=A4rvinen?= Cc: =?utf-8?q?Marek_Beh=C3=BAn?= Subject: [PATCH v3 04/17] firmware: turris-mox-rwtm: Use ETH_ALEN instead of hardcoded 6 Date: Mon, 17 Jun 2024 16:45:19 +0200 Message-ID: <20240617144532.17385-5-kabel@kernel.org> X-Mailer: git-send-email 2.44.2 In-Reply-To: <20240617144532.17385-1-kabel@kernel.org> References: <20240617144532.17385-1-kabel@kernel.org> MIME-Version: 1.0 Use the ETH_ALEN macro instead of hardcoded 6 for MAC address length. Signed-off-by: Marek Behún Reviewed-by: Ilpo Järvinen --- drivers/firmware/turris-mox-rwtm.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/firmware/turris-mox-rwtm.c b/drivers/firmware/turris-mox-rwtm.c index aafd747543f6..f7f9859b8f61 100644 --- a/drivers/firmware/turris-mox-rwtm.c +++ b/drivers/firmware/turris-mox-rwtm.c @@ -10,6 +10,7 @@ #include #include #include +#include #include #include #include @@ -69,7 +70,7 @@ struct mox_rwtm { int has_board_info; u64 serial_number; int board_version, ram_size; - u8 mac_address1[6], mac_address2[6]; + u8 mac_address1[ETH_ALEN], mac_address2[ETH_ALEN]; /* public key burned in eFuse */ int has_pubkey;