On Sat, Oct 14, 2023 at 7:36 PM Kees Cook wrote:
>
> On Sat, Oct 14, 2023 at 03:55:41AM +0200, Andrew Lunn wrote:
> > > I've been told that this whole ethtool API area is considered
> > > deprecated. If that holds, then I don't think it's worth adding new
> > > helpers to support it when ethtool_s
On Sat, Oct 14, 2023 at 03:55:41AM +0200, Andrew Lunn wrote:
> > I've been told that this whole ethtool API area is considered
> > deprecated. If that holds, then I don't think it's worth adding new
> > helpers to support it when ethtool_sprintf() is sufficient.
>
> I think deprecated is too stron
> I've been told that this whole ethtool API area is considered
> deprecated. If that holds, then I don't think it's worth adding new
> helpers to support it when ethtool_sprintf() is sufficient.
I think deprecated is too strong. The current API is not great, so
maybe with time a new API will emer
Hello:
This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski :
On Thu, 12 Oct 2023 22:25:12 + you wrote:
> strncpy() is deprecated for use on NUL-terminated destination strings
> [1] and as such we should prefer more robust and less ambiguous string
> interfaces.
>
> ethtool
On Thu, Oct 12, 2023 at 10:25:12PM +, Justin Stitt wrote:
> strncpy() is deprecated for use on NUL-terminated destination strings
> [1] and as such we should prefer more robust and less ambiguous string
> interfaces.
>
> ethtool_sprintf() is designed specifically for get_strings() usage.
> Let
On Fri, Oct 13, 2023 at 02:23:34PM -0700, Justin Stitt wrote:
> On Fri, Oct 13, 2023 at 2:12 PM Justin Stitt wrote:
> >
> > On Fri, Oct 13, 2023 at 1:13 PM Andrew Lunn wrote:
> > >
> > > On Fri, Oct 13, 2023 at 12:53:53PM -0700, Justin Stitt wrote:
> > > > On Fri, Oct 13, 2023 at 5:22 AM Andrew L
On Fri, Oct 13, 2023 at 2:12 PM Justin Stitt wrote:
>
> On Fri, Oct 13, 2023 at 1:13 PM Andrew Lunn wrote:
> >
> > On Fri, Oct 13, 2023 at 12:53:53PM -0700, Justin Stitt wrote:
> > > On Fri, Oct 13, 2023 at 5:22 AM Andrew Lunn wrote:
> > > >
> > > > > - for (i = 0; i < ARRAY_SIZE(tja11xx_hw_
On Fri, Oct 13, 2023 at 1:13 PM Andrew Lunn wrote:
>
> On Fri, Oct 13, 2023 at 12:53:53PM -0700, Justin Stitt wrote:
> > On Fri, Oct 13, 2023 at 5:22 AM Andrew Lunn wrote:
> > >
> > > > - for (i = 0; i < ARRAY_SIZE(tja11xx_hw_stats); i++) {
> > > > - strncpy(data + i * ETH_GSTRING
On Fri, Oct 13, 2023 at 12:53:53PM -0700, Justin Stitt wrote:
> On Fri, Oct 13, 2023 at 5:22 AM Andrew Lunn wrote:
> >
> > > - for (i = 0; i < ARRAY_SIZE(tja11xx_hw_stats); i++) {
> > > - strncpy(data + i * ETH_GSTRING_LEN,
> > > - tja11xx_hw_stats[i].string, ET
On Fri, Oct 13, 2023 at 5:22 AM Andrew Lunn wrote:
>
> > - for (i = 0; i < ARRAY_SIZE(tja11xx_hw_stats); i++) {
> > - strncpy(data + i * ETH_GSTRING_LEN,
> > - tja11xx_hw_stats[i].string, ETH_GSTRING_LEN);
> > - }
> > + for (i = 0; i < ARRAY_SIZE(tja11xx
> - for (i = 0; i < ARRAY_SIZE(tja11xx_hw_stats); i++) {
> - strncpy(data + i * ETH_GSTRING_LEN,
> - tja11xx_hw_stats[i].string, ETH_GSTRING_LEN);
> - }
> + for (i = 0; i < ARRAY_SIZE(tja11xx_hw_stats); i++)
> + ethtool_sprintf(&data, "%s", tj
strncpy() is deprecated for use on NUL-terminated destination strings
[1] and as such we should prefer more robust and less ambiguous string
interfaces.
ethtool_sprintf() is designed specifically for get_strings() usage.
Let's replace strncpy in favor of this dedicated helper function.
Link:
htt
12 matches
Mail list logo