From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christoph Hellwig Date: Tue, 9 Apr 2019 05:03:04 -0700 Subject: [Cluster-devel] [PATCH] libgfs2: Import gfs2_ondisk.h In-Reply-To: <20190409094153.3343-1-anprice@redhat.com> References: <20190409094153.3343-1-anprice@redhat.com> Message-ID: <20190409120304.GA16296@infradead.org> List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit On Tue, Apr 09, 2019 at 10:41:53AM +0100, Andrew Price wrote: > Give gfs2-utils its own copy of gfs2_ondisk.h which uses userspace > types. This allows us to always support the latest ondisk structures and > obsoletes a lot of #ifdef GFS2_HAS_ blocks and configure.ac > checks. > > gfs2_ondisk.h was changed simply by search-and-replace of the kernel int > types with the uintN_t, i.e.: > > :%s/__u\(8\|16\|32\|64\)/uint\1_t/g > :%s/__be\(64\|32\|16\|8\)/uint\1_t/g > > and the linux/types.h include replaced with stdint.h Why? At least the be types give you really useful type checking with sparse, which can be trivially wired up in userspace as well. Also keeping the file 1:1 the same is going to make your life much easier in the future..