From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail05.groups.io (mail05.groups.io [45.79.224.7]) by spool.mail.gandi.net (Postfix) with ESMTPS id B3C5894165E for ; Thu, 23 May 2024 10:56:05 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=kMVz5nXoYr3hWyaCd5KRcos3nFTgtsZByRi6BEpEJLs=; c=relaxed/simple; d=groups.io; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Resent-Date:Resent-From:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Transfer-Encoding; s=20240206; t=1716461764; v=1; b=mNmxKEnTcAyUVPWh5fLCUX/+3X0tmABo08SY8GE429moELyYijka0wqBXCya87unHmH456Ua z5yHWmx57wlKwFvICZfWnkYe08tzio9amJR8k9MWvmIL5CkReqHwV4equ4F0UQE6M8xUGR3mPQ+ lwSaKdZnRqu1nzFesmlbj7xaIQy+x/wMutUBNRC5B2oWuof/SE971iYcMWdjlLgSRGIF5i38hGw vqAMc4CONkbbsKynao0wG3hdvLfYMMfF+xnd5Jf9A22Zzky25Dt+kMxga0UA1IOxLxnUtmzNASX 0z9x6Fr90jltMx8V1BjpeM3E1iSFmGMLmVVDZOKlj2YwQ== X-Received: by 127.0.0.2 with SMTP id LR8wYY7687511xnspGDkqff5; Thu, 23 May 2024 03:56:04 -0700 X-Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by mx.groups.io with SMTP id smtpd.web11.14087.1716461763441461062 for ; Thu, 23 May 2024 03:56:03 -0700 X-Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 36E38339; Thu, 23 May 2024 03:56:27 -0700 (PDT) X-Received: from usa.arm.com (a077434.arm.com [10.162.46.143]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 714183F766; Thu, 23 May 2024 03:56:01 -0700 (PDT) From: "Sahil Kaushal" To: devel@edk2.groups.io Cc: Ard Biesheuvel , =?UTF-8?q?Leif=20Lindholm=20=C2=A0?= , Sami Mujawar , =?UTF-8?q?sahil=20=C2=A0?= Subject: [edk2-devel] [edk2-platforms][PATCH V3 06/17] Platform/ARM/NorFlashDxe: Make local functions STATIC Date: Thu, 23 May 2024 16:25:00 +0530 Message-Id: <20240523105511.13189-7-Sahil.Kaushal@arm.com> In-Reply-To: <20240523105511.13189-1-Sahil.Kaushal@arm.com> References: <20240523105511.13189-1-Sahil.Kaushal@arm.com> MIME-Version: 1.0 Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Resent-Date: Thu, 23 May 2024 03:56:03 -0700 Resent-From: sahil.kaushal@arm.com Reply-To: devel@edk2.groups.io,sahil.kaushal@arm.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: gLyBM944lNczi97zvDRuejVlx7686176AA= Content-Transfer-Encoding: quoted-printable X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20240206 header.b=mNmxKEnT; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=arm.com (policy=none); spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 45.79.224.7 as permitted sender) smtp.mailfrom=bounce@groups.io From: sahil This patch makes local functions not being used outside NorFlash.c STATIC. Also, NorFlashWriteBuffer() is specific to a particular flash implementation and need not be implemented by other NOR flash device IPs. Signed-off-by: sahil --- Platform/ARM/Drivers/NorFlashDxe/NorFlash.h | 21 -------------------- Platform/ARM/Drivers/NorFlashDxe/NorFlash.c | 3 +++ 2 files changed, 3 insertions(+), 21 deletions(-) diff --git a/Platform/ARM/Drivers/NorFlashDxe/NorFlash.h b/Platform/ARM/Dri= vers/NorFlashDxe/NorFlash.h index 3102c5e13bad..f30d499042ed 100644 --- a/Platform/ARM/Drivers/NorFlashDxe/NorFlash.h +++ b/Platform/ARM/Drivers/NorFlashDxe/NorFlash.h @@ -134,14 +134,6 @@ struct _NOR_FLASH_INSTANCE { NOR_FLASH_DEVICE_PATH DevicePath;=0D };=0D =0D -EFI_STATUS=0D -NorFlashWriteBuffer (=0D - IN NOR_FLASH_INSTANCE *Instance,=0D - IN UINTN TargetAddress,=0D - IN UINTN BufferSizeInBytes,=0D - IN UINT32 *Buffer=0D - );=0D -=0D //=0D // NorFlash.c=0D //=0D @@ -190,19 +182,6 @@ NorFlashEraseSingleBlock ( IN UINTN BlockAddress=0D );=0D =0D -EFI_STATUS=0D -NorFlashUnlockSingleBlockIfNecessary (=0D - IN NOR_FLASH_INSTANCE *Instance,=0D - IN UINTN BlockAddress=0D - );=0D -=0D -EFI_STATUS=0D -NorFlashWriteSingleWord (=0D - IN NOR_FLASH_INSTANCE *Instance,=0D - IN UINTN WordAddress,=0D - IN UINT32 WriteData=0D - );=0D -=0D EFI_STATUS=0D NorFlashWriteFullBlock (=0D IN NOR_FLASH_INSTANCE *Instance,=0D diff --git a/Platform/ARM/Drivers/NorFlashDxe/NorFlash.c b/Platform/ARM/Dri= vers/NorFlashDxe/NorFlash.c index 15000a692b02..254b8937e210 100644 --- a/Platform/ARM/Drivers/NorFlashDxe/NorFlash.c +++ b/Platform/ARM/Drivers/NorFlashDxe/NorFlash.c @@ -103,6 +103,7 @@ NorFlashUnlockSingleBlock ( return EFI_SUCCESS;=0D }=0D =0D +STATIC=0D EFI_STATUS=0D NorFlashUnlockSingleBlockIfNecessary (=0D IN NOR_FLASH_INSTANCE *Instance,=0D @@ -175,6 +176,7 @@ NorFlashEraseSingleBlock ( return Status;=0D }=0D =0D +STATIC=0D EFI_STATUS=0D NorFlashWriteSingleWord (=0D IN NOR_FLASH_INSTANCE *Instance,=0D @@ -245,6 +247,7 @@ NorFlashWriteSingleWord ( * Therefore, it is a requirement to align buffer writes to 32-bit word bo= undaries.=0D * i.e. the last 4 bits of the target start address must be zero: 0x......= 00=0D */=0D +STATIC=0D EFI_STATUS=0D NorFlashWriteBuffer (=0D IN NOR_FLASH_INSTANCE *Instance,=0D --=20 2.25.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#119148): https://edk2.groups.io/g/devel/message/119148 Mute This Topic: https://groups.io/mt/106260144/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=-