Subject: Re: CMSG_ALIGN
To: der Mouse <mouse@Rodents.Montreal.QC.CA>
From: None <itojun@iijlab.net>
List: tech-net
Date: 06/28/2003 08:20:24
>But my question was not "why is __cmsg_alignbytes there today", but
>rather,
>>> Why not, instead, have the kernel increase the cmsg_len values to
>>> whatever boundary it thinks appropriate?
>So that, for example, a cmsg_len that's natively 20 would be increased
>to 24 by the kernel (probably in recvit()'s loop), so that cmsg_len is
>_always_ the right amount for userland to advance its pointer by?

	cmsg is bidirectional.  when userland passes cmsg to kernel, we can
	not do such trick (userland does not know what kind of alignment
	kernel wants), so __cmsg_alignbytes is there for you.

itojun