Thread (2 messages) flat view 2 messages, 2 authors, 2025-05-15

Re: [PATCH] powerpc: Fix struct termio related ioctl macros

From: Tulio Magno Quites Machado Filho <hidden>
Date: 2025-05-15 20:10:42

Madhavan Srinivasan [off-list ref] writes:
Since termio interface is now obsolete, include/uapi/asm/ioctls.h
has some constant macros referring to "struct termio", this caused
build failure at userspace.

In file included from /usr/include/asm/ioctl.h:12,
                 from /usr/include/asm/ioctls.h:5,
                 from tst-ioctls.c:3:
tst-ioctls.c: In function 'get_TCGETA':
tst-ioctls.c:12:10: error: invalid application of 'sizeof' to incomplete type 'struct termio'
   12 |   return TCGETA;
      |          ^~~~~~

Even though termios.h provides "struct termio", trying to juggle definitions around to
make it compile could introduce regressions. So better to open code it.

Reported-by: Tulio Magno <redacted>
Closes: https://lore.kernel.org/linuxppc-dev/8734dji5wl.fsf@ascii.art.br/ (local)
Suggested-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Madhavan Srinivasan <maddy@linux.ibm.com>
I've tested and confirmed this patch does fix the issue.

Tested-by: Tulio Magno Quites Machado Filho <redacted>

Thank you!

-- 
Tulio Magno
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help