Message ID | cover.1602122879.git.joe@perches.com (mailing list archive) |
---|---|
Headers | show |
Series | RDMA: sprintf to sysfs_emit conversions | expand |
On Wed, Oct 07, 2020 at 07:36:23PM -0700, Joe Perches wrote: > A recent commit added a sysfs_emit and sysfs_emit_at to allow various > sysfs show functions to ensure that the PAGE_SIZE buffer argument is > never overrun and always NUL terminated. Unfortunately but the sysfs_emit commit is not in rdma-next tree yet. Thanks
On Thu, 2020-10-08 at 08:41 +0300, Leon Romanovsky wrote: > On Wed, Oct 07, 2020 at 07:36:23PM -0700, Joe Perches wrote: > > A recent commit added a sysfs_emit and sysfs_emit_at to allow various > > sysfs show functions to ensure that the PAGE_SIZE buffer argument is > > never overrun and always NUL terminated. > > Unfortunately but the sysfs_emit commit is not in rdma-next tree yet. Likely it'll still apply fairly well when the sysfs_emit commit is...
On Wed, Oct 07, 2020 at 10:52:15PM -0700, Joe Perches wrote: > On Thu, 2020-10-08 at 08:41 +0300, Leon Romanovsky wrote: > > On Wed, Oct 07, 2020 at 07:36:23PM -0700, Joe Perches wrote: > > > A recent commit added a sysfs_emit and sysfs_emit_at to allow various > > > sysfs show functions to ensure that the PAGE_SIZE buffer argument is > > > never overrun and always NUL terminated. > > > > Unfortunately but the sysfs_emit commit is not in rdma-next tree yet. > > Likely it'll still apply fairly well when the sysfs_emit commit is... Of course, we just can't take it yet and test it in automatic way like we are doing now. Thanks > >
On Thu, 2020-10-08 at 08:41 +0300, Leon Romanovsky wrote: > On Wed, Oct 07, 2020 at 07:36:23PM -0700, Joe Perches wrote: > > A recent commit added a sysfs_emit and sysfs_emit_at to allow various > > sysfs show functions to ensure that the PAGE_SIZE buffer argument is > > never overrun and always NUL terminated. > > Unfortunately but the sysfs_emit commit is not in rdma-next tree yet. It is in Linus' tree now.
On Wed, Oct 07, 2020 at 07:36:23PM -0700, Joe Perches wrote: > A recent commit added a sysfs_emit and sysfs_emit_at to allow various > sysfs show functions to ensure that the PAGE_SIZE buffer argument is > never overrun and always NUL terminated. > > Convert the RDMA/InfiniBand subsystem to use these new functions. > > The first 2 patches exclusively used coccinelle to convert uses. > The third and fourth patches were done manually. > > Compiled allyesconfig and defconfig with all infiniband options selected > no warnings, but untested, no hardward > > Overall object size is reduced > > total size: allyesconfig x86-64 > new: 8364003 1680968 131520 10176491 9b47eb (TOTALS) > old: 8365883 1681032 131520 10178435 9b4f83 (TOTALS) > > total size: defconfig x86-64 with all infiniband selected > new; 1359153 131228 1910 1492291 16c543 (TOTALS) > old: 1359422 131228 1910 1492560 16c650 (TOTALS) > > Joe Perches (4): > RDMA: Convert sysfs device * show functions to use sysfs_emit() > RDMA: Convert sysfs kobject * show functions to use sysfs_emit() First two applied to for-next > RDMA: manual changes for sysfs_emit and neatening > RDMA: Convert various random sprintf sysfs _show uses to sysfs_emit Will probably do these two later this week/next Thanks, Jason
On Wed, Oct 07, 2020 at 07:36:23PM -0700, Joe Perches wrote: > Joe Perches (4): > RDMA: manual changes for sysfs_emit and neatening > RDMA: Convert various random sprintf sysfs _show uses to sysfs_emit Applied to rdma for-next, thanks Jason