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:   Tue, 5 Sep 2023 12:57:34 +0300
From:   Dan Carpenter <dan.carpenter@...aro.org>
To:     Ratheesh Kannoth <rkannoth@...vell.com>
Cc:     netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
        davem@...emloft.net, edumazet@...gle.com, kuba@...nel.org,
        pabeni@...hat.com, ast@...nel.org, daniel@...earbox.net,
        hawk@...nel.org, john.fastabend@...il.com, jiawenwu@...stnetic.com,
        mengyuanlou@...-swift.com, yang.lee@...ux.alibaba.com,
        error27@...il.com, linyunsheng@...wei.com,
        linux-hyperv@...r.kernel.org, kys@...rosoft.com,
        haiyangz@...rosoft.com, wei.liu@...nel.org, decui@...rosoft.com,
        longli@...rosoft.com, shradhagupta@...ux.microsoft.com,
        linux-hwmon@...r.kernel.org, michael.chan@...adcom.com,
        richardcochran@...il.com, jdelvare@...e.com, linux@...ck-us.net,
        yisen.zhuang@...wei.com, salil.mehta@...wei.com,
        linux-arm-kernel@...ts.infradead.org,
        linux-mediatek@...ts.infradead.org, nbd@....name, john@...ozen.org,
        sean.wang@...iatek.com, Mark-MC.Lee@...iatek.com,
        lorenzo@...nel.org, matthias.bgg@...il.com,
        angelogioacchino.delregno@...labora.com, linux@...linux.org.uk,
        linux-rdma@...r.kernel.org, saeedm@...dia.com, leon@...nel.org,
        gerhard@...leder-embedded.com, maciej.fijalkowski@...el.com,
        alexanderduyck@...com, wei.fang@....com, shenwei.wang@....com,
        xiaoning.wang@....com, linux-imx@....com, lgirdwood@...il.com,
        broonie@...nel.org, jaswinder.singh@...aro.org,
        ilias.apalodimas@...aro.org, UNGLinuxDriver@...rochip.com,
        horatiu.vultur@...rochip.com, linux-omap@...r.kernel.org,
        grygorii.strashko@...com, simon.horman@...igine.com,
        vladimir.oltean@....com, aleksander.lobakin@...el.com,
        linux-stm32@...md-mailman.stormreply.com,
        alexandre.torgue@...s.st.com, joabreu@...opsys.com,
        mcoquelin.stm32@...il.com, p.zabel@...gutronix.de,
        thomas.petazzoni@...tlin.com, mw@...ihalf.com,
        sgoutham@...vell.com, gakula@...vell.com, sbhatta@...vell.com,
        hkelam@...vell.com, xen-devel@...ts.xenproject.org,
        jgross@...e.com, sstabellini@...nel.org,
        oleksandr_tyshchenko@...m.com, linux-wireless@...r.kernel.org,
        ryder.lee@...iatek.com, shayne.chen@...iatek.com, kvalo@...nel.org,
        andrii@...nel.org, martin.lau@...ux.dev, song@...nel.org,
        yonghong.song@...ux.dev, kpsingh@...nel.org, sdf@...gle.com,
        haoluo@...gle.com, jolsa@...nel.org
Subject: Re: [PATCH v1 net] page_pool: Cap queue size to 32k.

On Mon, Aug 14, 2023 at 11:34:11AM +0530, Ratheesh Kannoth wrote:
> Clamp to 32k instead of returning error.

What is the motivation here?  What is the real world impact for the
users?

> 
> Please find discussion at
> https://lore.kernel.org/lkml/
> CY4PR1801MB1911E15D518A77535F6E51E2D308A@...PR1801MB1911.
> namprd18.prod.outlook.com/T/

Please don't break the URL up like this.  I think normally we would just
write up a normal commit message and use the Link: tag.

Fixes: ff7d6b27f894 ("page_pool: refurbish version of page_pool code")
Link: https://lore.kernel.org/lkml/CY4PR1801MB1911E15D518A77535F6E51E2D308A@CY4PR1801MB1911.namprd18.prod.outlook.com/
Signed-off-by:

> @@ -171,9 +171,10 @@ static int page_pool_init(struct page_pool *pool,
>  	if (pool->p.pool_size)
>  		ring_qsize = pool->p.pool_size;
>  
> -	/* Sanity limit mem that can be pinned down */
> +	/* Cap queue size to 32k */
>  	if (ring_qsize > 32768)
> -		return -E2BIG;
> +		ring_qsize = 32768;
> +
>  
>  	/* DMA direction is either DMA_FROM_DEVICE or DMA_BIDIRECTIONAL.

Don't introduce a blank line here.  Checkpatch will complain if you
have to blank lines in a row.  It won't complain about the patch but it
will complain if you apply the patch and then re-run checkpatch -f on
the file.  (I didn't test this but it's wrong either way. :P).

regards,
dan carpenter

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ