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] [day] [month] [year] [list]
Date:   Wed, 07 Nov 2018 22:33:11 -0800 (PST)
From:   David Miller <davem@...emloft.net>
To:     madalin.bucur@....com
Cc:     netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] dpaa_eth: add ethtool coalesce control

From: Madalin Bucur <madalin.bucur@....com>
Date: Wed,  7 Nov 2018 15:53:43 +0200

> +static int dpaa_set_coalesce(struct net_device *dev,
> +			     struct ethtool_coalesce *c)
> +{
> +	const cpumask_t *cpus = qman_affine_cpus();
> +	struct qman_portal *portal;
> +	u32 period;
> +	u8 thresh;
> +	int cpu;
> +
> +	period = c->rx_coalesce_usecs;
> +	thresh = c->rx_max_coalesced_frames;
> +
> +	for_each_cpu(cpu, cpus) {
> +		portal = qman_get_affine_portal(cpu);
> +		qman_portal_set_iperiod(portal, period);
> +		qman_dqrr_set_ithresh(portal, thresh);
> +	}

You really have to check to see if the user is trying to configure
a setting you don't support, for example if the user tries
to set ->use_adative_rx_coalesce or uses a period or threshold
value which is out of range.

Thanks.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ