In libgfs2 we have a mix of function names prefixed with gfs2_, lgfs2_ or 
nothing at all that denotes where they are defined. This patch set addresses 
that problem by more strictly enforcing a prefix namespace scheme on the 
symbols exposed by libgfs2. So now we (mostly) have these prefix conventions:

GFS2_/gfs2_   - kernel code
LGFS2_/lgfs2_ - libgfs2 interfaces
No prefix     - application/internal code

This means we can tell at a glance where names are defined, which makes the 
code easier to work with.

Some changes that were not made in this set are:

- gfs(1) on-disk structures defined in libgfs2.h for compatibility were not 
renamed as they're essentially kernel-defined.
- The endianness conversion macros (be64_to_cpu(), etc.) were not renamed but 
they will likely be renamed once a concise naming scheme has been decided upon.

This is obviously a large amount of churn but it pays off a lot of technical 
debt and I think it's worth getting it out of the way in one go. Many of the 
changes were scripted but each patch was reviewed by eye and tested with 'make 
check'.

Andrew Price (21):
  libgfs2: Namespace improvements - structures.c
  libgfs2: Namespace improvements - buf.c
  libgfs2: Namespace improvements - fs_ops.c
  libgfs2: Namespace improvements - fs_bits.c
  libgfs2: Namespace improvements - gfs1.c
  libgfs2: Namespace improvements - misc.c
  libgfs2: Namespace improvements - rgrp.c
  libgfs2: Namespace improvements - super.c
  libgfs2: Namespace improvements - gfs2_disk_hash.c
  libgfs2: Remove revoke function declarations from libgfs2.h
  libgfs2: Namespace improvements - recovery.c
  libgfs2: Namespace improvements - device_geometry.c
  libgfs2: Namespace improvements - struct gfs2_inode
  libgfs2: Namespace improvements - struct gfs2_buffer_head
  libgfs2: Namespace improvements - struct gfs2_sbd
  libgfs2: Namespace improvements - struct metapath
  libgfs2: Namespace improvements - struct master_dir
  libgfs2: Namespace improvements - struct device
  libgfs2: Namespace improvements - struct gfs2_bitmap
  libgfs2: Namespace improvements - constants
  libgfs2: Namespace improvements - struct rgrp_tree

 gfs2/convert/gfs2_convert.c    | 398 +++++++++++------------
 gfs2/edit/extended.c           |  72 ++---
 gfs2/edit/gfs2hex.c            |   8 +-
 gfs2/edit/hexedit.c            | 198 ++++++------
 gfs2/edit/hexedit.h            |   6 +-
 gfs2/edit/journal.c            |  84 ++---
 gfs2/edit/savemeta.c           |  32 +-
 gfs2/fsck/afterpass1_common.c  |  54 ++--
 gfs2/fsck/afterpass1_common.h  |  26 +-
 gfs2/fsck/fs_recovery.c        | 206 ++++++------
 gfs2/fsck/fs_recovery.h        |  10 +-
 gfs2/fsck/fsck.h               |  46 +--
 gfs2/fsck/initialize.c         | 278 ++++++++--------
 gfs2/fsck/link.c               |   6 +-
 gfs2/fsck/link.h               |   4 +-
 gfs2/fsck/lost_n_found.c       |  34 +-
 gfs2/fsck/lost_n_found.h       |   4 +-
 gfs2/fsck/main.c               |  38 +--
 gfs2/fsck/metawalk.c           | 178 +++++------
 gfs2/fsck/metawalk.h           |  70 ++---
 gfs2/fsck/pass1.c              | 356 ++++++++++-----------
 gfs2/fsck/pass1b.c             | 118 +++----
 gfs2/fsck/pass2.c              | 278 ++++++++--------
 gfs2/fsck/pass3.c              |  14 +-
 gfs2/fsck/pass4.c              |  24 +-
 gfs2/fsck/pass5.c              |  28 +-
 gfs2/fsck/rgrepair.c           | 222 ++++++-------
 gfs2/fsck/util.c               |  18 +-
 gfs2/fsck/util.h               |  26 +-
 gfs2/glocktop/glocktop.c       |  18 +-
 gfs2/libgfs2/buf.c             |  28 +-
 gfs2/libgfs2/check_ondisk.c    |   6 +-
 gfs2/libgfs2/check_rgrp.c      |   8 +-
 gfs2/libgfs2/device_geometry.c |   4 +-
 gfs2/libgfs2/fs_bits.c         |  32 +-
 gfs2/libgfs2/fs_ops.c          | 557 ++++++++++++++++-----------------
 gfs2/libgfs2/gfs1.c            |  82 ++---
 gfs2/libgfs2/gfs2_disk_hash.c  |   5 +-
 gfs2/libgfs2/gfs2l.c           |  20 +-
 gfs2/libgfs2/lang.c            |  40 +--
 gfs2/libgfs2/lang.h            |   2 +-
 gfs2/libgfs2/libgfs2.h         | 319 +++++++++----------
 gfs2/libgfs2/misc.c            |   8 +-
 gfs2/libgfs2/ondisk.c          |   8 +-
 gfs2/libgfs2/recovery.c        |  38 +--
 gfs2/libgfs2/rgrp.c            |  88 +++---
 gfs2/libgfs2/rgrp.h            |   4 +-
 gfs2/libgfs2/structures.c      | 168 +++++-----
 gfs2/libgfs2/super.c           |  48 +--
 gfs2/mkfs/main_grow.c          |  32 +-
 gfs2/mkfs/main_jadd.c          |  24 +-
 gfs2/mkfs/main_mkfs.c          | 104 +++---
 gfs2/tune/super.c              |   6 +-
 tests/nukerg.c                 |  22 +-
 54 files changed, 2243 insertions(+), 2264 deletions(-)

-- 
2.34.1

Reply via email to