From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f66.google.com (mail-wm1-f66.google.com [209.85.128.66]) by mx.groups.io with SMTP id smtpd.web11.7457.1579272877020909622 for ; Fri, 17 Jan 2020 06:54:37 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@linaro.org header.s=google header.b=Y8ejlOIz; spf=pass (domain: linaro.org, ip: 209.85.128.66, mailfrom: ard.biesheuvel@linaro.org) Received: by mail-wm1-f66.google.com with SMTP id u2so7908180wmc.3 for ; Fri, 17 Jan 2020 06:54:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=fFTh/L53zqcTxlnD+GmApVjZJ4HcmNjKkrAk/97hvRo=; b=Y8ejlOIz9RTmQKILWAklbBgqAwYMeS34aQPAfmUZ9YG4hJyqpPYOGeTH72z1ea8p+P /f8IYGYfVpsVeISA9faRHM/zOVq/EAoZiu7C3uCbJk5LEaiAXiiNCVUn7XjRzHvYmI4l KGn9jglGQ8CM7WWZem6oUO3QPdVmRflrFiJ1nLLNwYL/jxDcBCK+ZeiGiWhnrdbWexKx TBORfgUgNyJ9kmTPXQ+sZ8MeF228wZ9f/1sxGzn53ZzskEBuKmtfjqr1uBUrukmeePso LM7eqf0Gi12JfkRfNzhiMtze7Q2IMNK6ZRfRStP1UeikAUOIKLzyWaVZmS8of0qz8EdI GwgA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=fFTh/L53zqcTxlnD+GmApVjZJ4HcmNjKkrAk/97hvRo=; b=qhk/7XHO6ehDRe46dx9i6yIqiZyZrBpJW7V/ZUrTTZJMTfc9AfEceL8kKJRi0rDXQx JPjv7iDY2Z/XjXJwAY3O+r3BysQNisgjtqj4bQaKRqUyhygJR/m9zJQicmB9vxQTx84E qKk7ztINueG+sIlLyk4HzHb0mIxDRIWdrOMm3jqrvq7DBGw3FWWEdLFKw90Ayxxi9JjU 8WGOMvMNnwvItPhwcsZ2o4nAe2uAKgqDLs8KCZ9vm/Wc3VDdQLGZHGT/AC0ZpRE+kQOr FjBbk2i8a65vKHdILlS5mnVG9M2vpBDoaFC3+Cne34NNzMnflEZeRyDOsBYFez18yzXJ wq9A== X-Gm-Message-State: APjAAAW88wX6pJQdvkJaCt6akH2dRUBVcIG8yku6RWHFiSRUMQz5cndx F5qrKpx8rQuOxHnAHWsYdWeqrmr/rF+WNB9VbZdLyg== X-Google-Smtp-Source: APXvYqyHz3W47z7MyyMBLeLuSR+MR+Bt8gb9pZua+EX73bg7tPAg9v9dySvssibkHVw3/SoAXhNM2JU4B3HKVX/EE38= X-Received: by 2002:a1c:a406:: with SMTP id n6mr4931996wme.40.1579272875588; Fri, 17 Jan 2020 06:54:35 -0800 (PST) MIME-Version: 1.0 References: <20200117111651.10740-1-ard.biesheuvel@linaro.org> <20200117130659.GL20629@bivouac.eciton.net> In-Reply-To: <20200117130659.GL20629@bivouac.eciton.net> From: "Ard Biesheuvel" Date: Fri, 17 Jan 2020 15:54:24 +0100 Message-ID: Subject: Re: [PATCH edk2-platforms] Silicon/SynQuacer/NetsecDxe: ignore DMA coherency at binding time To: Leif Lindholm Cc: edk2-devel-groups-io Content-Type: text/plain; charset="UTF-8" On Fri, 17 Jan 2020 at 14:07, Leif Lindholm wrote: > > On Fri, Jan 17, 2020 at 12:16:51 +0100, Ard Biesheuvel wrote: > > 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 > > Reviewed-by: Leif Lindholm > Pushed as a327627dd3f9..3465bb1a1855 Thanks, > > --- > > 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 > >