lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 19 Nov 2020 12:21:15 -0800
From:   Saeed Mahameed <saeed@...nel.org>
To:     David Awogbemila <awogbemila@...gle.com>, netdev@...r.kernel.org
Cc:     Catherine Sullivan <csully@...gle.com>,
        Yangchun Fu <yangchun@...gle.com>
Subject: Re: [PATCH net-next v7 1/4] gve: Add support for raw addressing
 device option

On Wed, 2020-11-18 at 15:20 -0800, David Awogbemila wrote:
> From: Catherine Sullivan <csully@...gle.com>
> 
> Add support to describe device for parsing device options. As
> the first device option, add raw addressing.
> 
> "Raw Addressing" mode (as opposed to the current "qpl" mode) is an
> operational mode which allows the driver avoid bounce buffer copies
> which it currently performs using pre-allocated qpls
> (queue_page_lists)
> when sending and receiving packets.
> For egress packets, the provided skb data addresses will be
> dma_map'ed and
> passed to the device, allowing the NIC can perform DMA directly - the
> driver will not have to copy the buffer content into pre-allocated
> buffers/qpls (as in qpl mode).
> For ingress packets, copies are also eliminated as buffers are handed
> to
> the networking stack and then recycled or re-allocated as
> necessary, avoiding the use of skb_copy_to_linear_data().
> 
> This patch only introduces the option to the driver.
> Subsequent patches will add the ingress and egress functionality.
> 
> Reviewed-by: Yangchun Fu <yangchun@...gle.com>
> Signed-off-by: Catherine Sullivan <csully@...gle.com>
> Signed-off-by: David Awogbemila <awogbemila@...gle.com>
> ---
> 
...
> diff --git a/drivers/net/ethernet/google/gve/gve_adminq.c
> b/drivers/net/ethernet/google/gve/gve_adminq.c
> index 24ae6a28a806..1e2d407cb9d2 100644
> --- a/drivers/net/ethernet/google/gve/gve_adminq.c
> +++ b/drivers/net/ethernet/google/gve/gve_adminq.c
> @@ -14,6 +14,57 @@
>  #define GVE_ADMINQ_SLEEP_LEN		20
>  #define GVE_MAX_ADMINQ_EVENT_COUNTER_CHECK	100
>  
> +#define GVE_DEVICE_OPTION_ERROR_FMT "%s option error:\n" \
> +"Expected: length=%d, feature_mask=%x.\n" \
> +"Actual: length=%d, feature_mask=%x.\n"
> +
> +static inline
> +struct gve_device_option *gve_get_next_option(struct
> 

Following Dave's policy, no static inline functions in C files.
This is control path so you don't really need the inline here.



Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ