Skip to content

Commit

Permalink
Clean up global BuildOptions
Browse files Browse the repository at this point in the history
Signed-off-by: Mario Bălănică <[email protected]>
  • Loading branch information
mariobalanica committed Jan 20, 2025
1 parent 306ff58 commit 1031e5c
Show file tree
Hide file tree
Showing 12 changed files with 11 additions and 43 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ GetPca9555Protocol (
EFI_HANDLE *HandleBuffer;
EFI_STATUS Status;
UINTN HandleCount;
UINTN Index;

/* Locate Handles of all PCA95XX_PROTOCOL producers */
Status = gBS->LocateHandleBuffer (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -266,8 +266,6 @@ LcdGraphicsOutputInit (
UINTN ConnectorCount;
EFI_HANDLE *ConnectorHandles;
UINTN Index;
UINT32 HorizontalResolution;
UINT32 VerticalResolution;

Status = LcdInstanceContructor (&Instance);
if (EFI_ERROR (Status)) {
Expand Down
23 changes: 0 additions & 23 deletions edk2-rockchip/Silicon/Rockchip/Drivers/OhciDxe/Ohci.c
Original file line number Diff line number Diff line change
Expand Up @@ -9,29 +9,6 @@ SPDX-License-Identifier: BSD-2-Clause-Patent

#include "Ohci.h"

STATIC OHCI_DEVICE_PATH OhciDevicePathProtocol = {
{
{
HARDWARE_DEVICE_PATH,
HW_VENDOR_DP,
{
(UINT8)(OFFSET_OF (OHCI_DEVICE_PATH, End)),
(UINT8)(OFFSET_OF (OHCI_DEVICE_PATH, End) >> 8),
},
},
EFI_CALLER_ID_GUID
},
0, // Instance
{
END_DEVICE_PATH_TYPE,
END_ENTIRE_DEVICE_PATH_SUBTYPE,
{
sizeof (EFI_DEVICE_PATH_PROTOCOL),
0
}
}
};

/**
Provides software reset for the USB host controller.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -465,8 +465,6 @@ Pca9555ValidatePin (
IN UINTN GpioPin
)
{
UINTN ControllerId;

if (GpioPin >= PCA9555_NUM_GPIO) {
DEBUG ((
DEBUG_ERROR,
Expand Down Expand Up @@ -510,8 +508,6 @@ Pca9555Get (
EFI_I2C_IO_PROTOCOL *I2cIo;
EFI_STATUS Status;
UINTN GpioPin;
UINT8 RegVal;
UINTN Bank;

GpioPin = GPIO_PIN (Gpio);

Expand Down Expand Up @@ -747,7 +743,6 @@ Pca9555Supported (
EFI_I2C_IO_PROTOCOL *TmpI2cIo;
UINT8 Pca9555Address = 0x00;
UINT8 Pca9555Bus = 0x00;
UINTN i;

Status = gBS->OpenProtocol (
ControllerHandle,
Expand Down Expand Up @@ -850,7 +845,7 @@ Pca9555Stop (
IN EFI_HANDLE *ChildHandleBuffer OPTIONAL
)
{
EFI_STATUS Status = EFI_SUCCESS;
// EFI_STATUS Status = EFI_SUCCESS;

gBS->UninstallMultipleProtocolInterfaces (
&ControllerHandle,
Expand Down
2 changes: 1 addition & 1 deletion edk2-rockchip/Silicon/Rockchip/Drivers/RkFvbDxe/RkFvbDxe.c
Original file line number Diff line number Diff line change
Expand Up @@ -1055,7 +1055,7 @@ FvbConfigureFlashInstance (
{
EFI_STATUS Status;
UINTN DataOffset;
UINTN VariableSize, FtwWorkingSize, FtwSpareSize, MemorySize;
UINTN VariableSize, FtwWorkingSize, FtwSpareSize;

// Locate SPI protocols
Status = gBS->LocateProtocol (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1406,7 +1406,7 @@ static int dw_dp_connector_init(ROCKCHIP_CONNECTOR_PROTOCOL *conn, DISPLAY_STATE
{
CONNECTOR_STATE *conn_state = &state->ConnectorState;
struct dw_dp *dp = DW_DP_FROM_CONNECTOR_PROTOCOL (conn);
int ret;
int ret = 0;

conn_state->OutputInterface |= dp->id ? VOP_OUTPUT_IF_DP1 : VOP_OUTPUT_IF_DP0;
conn_state->OutputMode = ROCKCHIP_OUT_MODE_AAAA;
Expand Down
3 changes: 3 additions & 0 deletions edk2-rockchip/Silicon/Rockchip/Library/DisplayLib/DwDpLib.inf
Original file line number Diff line number Diff line change
Expand Up @@ -46,5 +46,8 @@
gRockchipConnectorProtocolGuid ## PRODUCES
gDpPhyProtocolGuid ## CONSUMES

[BuildOptions]
GCC:*_*_AARCH64_CC_FLAGS = -Wno-error=unused-function -Wno-error=unused-variable

[Depex]
TRUE
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,14 @@
Silicon/Rockchip/RockchipPkg.dec
Silicon/Rockchip/RK3588/RK3588.dec

[BuildOptions]

[Pcd]

[Protocols]
gRockchipConnectorProtocolGuid ## PRODUCES
gRockchipDsiPanelProtocolGuid ## CONSUMES

[BuildOptions]
GCC:*_*_AARCH64_CC_FLAGS = -Wno-error=unused-function -Wno-error=unused-variable

[Depex]
TRUE
Original file line number Diff line number Diff line change
Expand Up @@ -538,7 +538,7 @@ static int udphy_disable(struct rockchip_udphy *udphy)

static int udphy_parse_lane_mux_data(struct rockchip_udphy *udphy, UINT8 *prop, UINTN num_lanes)
{
int ret, i;
int i;

if (!prop) {
dev_dbg(udphy->dev,
Expand Down
4 changes: 1 addition & 3 deletions edk2-rockchip/Silicon/Rockchip/Rockchip.dsc.inc
Original file line number Diff line number Diff line change
Expand Up @@ -356,9 +356,7 @@ FspiLib|Silicon/Rockchip/Library/FspiLib/FspiLib.inf
###################################################################################################

[BuildOptions]
# RVCT:RELEASE_*_*_CC_FLAGS = -DMDEPKG_NDEBUG
*_*_*_CC_FLAGS = -DDEFAULT_DARK
GCC:*_*_AARCH64_CC_FLAGS = -Wno-error=uninitialized -Wno-error=stringop-overflow -Wno-error=unused-function -Wno-error=unused-variable
GCC:*_*_AARCH64_CC_FLAGS = -Wno-error=unused-function

# Compile with symbols to support overlays.
*_*_*_DTC_FLAGS = -@
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -609,7 +609,6 @@ DwMmcHcDriverBindingStart (

NON_DISCOVERABLE_DEVICE *Dev;

BOOLEAN MediaPresent;
DWMMC_CARD_TYPE_DETECT_ROUTINE *Routine;
UINT8 Index;
UINT32 RoutineNum;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -595,8 +595,6 @@ DwMmcHcStartDma (
UINTN DevBase;
UINT32 Ctrl;
UINT32 Bmod;
UINT32 Timeout;
UINT32 Data;

// DevIo = Trb->Private->DevIo;
DevBase = Trb->Private->DevBase;
Expand Down

0 comments on commit 1031e5c

Please sign in to comment.