From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wr1-f67.google.com (mail-wr1-f67.google.com [209.85.221.67]) by mx.groups.io with SMTP id smtpd.web10.5161.1579259816495095406 for ; Fri, 17 Jan 2020 03:16:57 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@linaro.org header.s=google header.b=aMxC5PjM; spf=pass (domain: linaro.org, ip: 209.85.221.67, mailfrom: ard.biesheuvel@linaro.org) Received: by mail-wr1-f67.google.com with SMTP id d16so22320095wre.10 for ; Fri, 17 Jan 2020 03:16:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=WnBOwPZOmwVNEG4WD2T0JA5w9JWewnk3dwP3qCR74BY=; b=aMxC5PjM0lLFMciqTr3JP4hB1kj4Ql8rSkJarvYD6IZlKfs+lb0YGlRtkr5GGdR9wL hGJ6Cid/uLDHuRsrnQja0WMTtchQsP1AugQNz2PbT+o9XVuE0T2lb8+Np0bUPqACZhwk ShKg0P9pkBhEA12j9fMgsd4q/w8+MatB8XX6A54Xa7VSwjrnRfa59xddBPGH+xN2pdbq n2We7P4wNPSEBcs+vj9MyyHJ5WTZ1acl02gui4eAg7AQd4bcEtj9FWWlT99XDDr20v4H zZpky/AhOwrh3Wn5Jla4dz0r9SHemH76s3uz2FsuRHi99RihCNjL2Ye7qMYAzBO1yYxT URTA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=WnBOwPZOmwVNEG4WD2T0JA5w9JWewnk3dwP3qCR74BY=; b=P8dETa6uEKkUo0n9c0aYiFz2Zjk4NGbO1wRag5rq9MWKelfmrnfDP7DG1TZ2AZ4riZ 6Xo6RbVsGUoAJbTrlYg9SXLhyCw3/1xkV7LGNUTO7Xqbw3+E+zFZAZmmXSXriIq2jwt2 X32+JWNZZgTZItuPPI+65giqCamik6zvfTZcE2amUGG19kjVOKtvJ+PoVx8TqSOt99v6 mbj01i+sMcyJQ//kKc6qkl3OF8SkfFK/NqCX8jaOhlywVTrYvt21MvD/xijs6PCHE1JK HUn/F0mcUAWLWQQaOO9RZ1Q4WBy0YTPC55DdcNQtcomaaeHYXr5vHYI8amBIurKFFpF6 yI6w== X-Gm-Message-State: APjAAAV4yqS7ob8M/6m/ZzOcTrAFleXuZVwXHAgoPHdnRsjTgkwHsfIn m7nmRPuog33YMazCmxmZmVHq3TeVwAKUmA== X-Google-Smtp-Source: APXvYqzhtX1z3zA0oLyYSMCQr7aKSdK3xzRpy3rlu2iMoZUHpi+itDBjf7CxDfpgjOvB1ovchyOAsA== X-Received: by 2002:adf:e6c6:: with SMTP id y6mr2480503wrm.284.1579259814813; Fri, 17 Jan 2020 03:16:54 -0800 (PST) Return-Path: Received: from dogfood.home ([2a01:cb1d:112:6f00:d1a2:6463:e9f:6fd0]) by smtp.gmail.com with ESMTPSA id p5sm31957259wrt.79.2020.01.17.03.16.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 17 Jan 2020 03:16:54 -0800 (PST) From: "Ard Biesheuvel" To: devel@edk2.groups.io Cc: leif.lindholm@linaro.org, Ard Biesheuvel Subject: [PATCH edk2-platforms] Silicon/SynQuacer/NetsecDxe: ignore DMA coherency at binding time Date: Fri, 17 Jan 2020 12:16:51 +0100 Message-Id: <20200117111651.10740-1-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Whether the Netsec driver is built to support coherent or non-coherent DMA is decided by the DmaLib library class resolution that is provided by the platform description, and there are various other places where the platform needs to be consistent with this (ACPI tables, device tree, platform driver, etc) Since the driver has no way to figure out which flavor of DmaLib it was built against, there is no point in limiting it to one flavor only, and we can drop the DmaType check at binding time entirely. This fixes an issue introduced by commit 88c7874481b856578662b775 ("Silicon/SynQuacer/PlatformDxe: set NETSEC DMA as coherent"), which incorrectly stated that the driver does not look at the DmaType flag in the first place. Signed-off-by: Ard Biesheuvel --- Silicon/Socionext/SynQuacer/Drivers/Net/NetsecDxe/DriverBinding.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Silicon/Socionext/SynQuacer/Drivers/Net/NetsecDxe/DriverBinding.c b/Silicon/Socionext/SynQuacer/Drivers/Net/NetsecDxe/DriverBinding.c index 9820585e0dd5..392d1b474f5e 100644 --- a/Silicon/Socionext/SynQuacer/Drivers/Net/NetsecDxe/DriverBinding.c +++ b/Silicon/Socionext/SynQuacer/Drivers/Net/NetsecDxe/DriverBinding.c @@ -52,8 +52,7 @@ NetsecDriverBindingSupported ( return Status; } - if (CompareGuid (Dev->Type, &gNetsecNonDiscoverableDeviceGuid) && - Dev->DmaType == NonDiscoverableDeviceDmaTypeNonCoherent) { + if (CompareGuid (Dev->Type, &gNetsecNonDiscoverableDeviceGuid)) { Status = EFI_SUCCESS; } else { Status = EFI_UNSUPPORTED; -- 2.20.1