On Wed, Oct 9, 2024 at 4:28 AM Jakub Kicinski <kuba@xxxxxxxxxx> wrote: > > On Thu, 3 Oct 2024 11:49:50 -0700 Mina Almasry wrote: > > > > + dev->ethtool_ops->get_ringparam(dev, &ringparam, > > > > + &kernel_ringparam, extack); > > > > + if (kernel_ringparam.tcp_data_split != ETHTOOL_TCP_DATA_SPLIT_ENABLED || > > > > + kernel_ringparam.tcp_data_split_thresh) { > > > > + NL_SET_ERR_MSG(extack, > > > > + "tcp-header-data-split is disabled or threshold is not zero"); > > > > + return -EINVAL; > > > > + } > > > > + > > > Maybe just my personal opinion, but IMHO these checks should be separate > > > so the error message can be more concise/clear. > > > > > > > Good point. The error message in itself is valuable. > > If you mean that the error message is more intuitive than debugging why > PP_FLAG_ALLOW_UNREADABLE_NETMEM isn't set - I agree :) > > I vote to keep the patch, FWIW. Maybe add a comment that for now drivers > should not set PP_FLAG_ALLOW_UNREADABLE_NETMEM, anyway, but this gives > us better debuggability, and in the future we may find cases where > doing a copy is cheaper than buffer circulation (and therefore may lift > this check). Okay, I will not drop this patch in v4 patch. So, I just will fix what Brett and Mina pointed out.