mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Richard Kennedy <richard@rsk.demon.co.uk>
To: matthew@wil.cx
Cc: lkml <linux-kernel@vger.kernel.org>
Subject: [PATCH] file lock: reorder struct file_lock to save space on 64 bit builds
Date: Tue, 24 Jun 2008 10:18:24 +0100	[thread overview]
Message-ID: <1214299104.3815.5.camel@castor.localdomain> (raw)

reduce sizeof struct file_lock by 8 on 64 bit builds allowing +1 objects
per slab in the file_lock_cache
    
Signed-off-by: Richard Kennedy <richard@rsk.demon.co.uk>

---

patch against 2.6.26-rc7
successfully running on AMD64 desktop.

Richard
 


diff --git a/include/linux/fs.h b/include/linux/fs.h
index d490779..a0735d7 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -919,12 +919,12 @@ struct file_lock {
 	struct list_head fl_link;	/* doubly linked list of all locks */
 	struct list_head fl_block;	/* circular list of blocked processes */
 	fl_owner_t fl_owner;
+	unsigned char fl_flags;
+	unsigned char fl_type;
 	unsigned int fl_pid;
 	struct pid *fl_nspid;
 	wait_queue_head_t fl_wait;
 	struct file *fl_file;
-	unsigned char fl_flags;
-	unsigned char fl_type;
 	loff_t fl_start;
 	loff_t fl_end;
 



                 reply	other threads:[~2008-06-24  9:19 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1214299104.3815.5.camel@castor.localdomain \
    --to=richard@rsk.demon.co.uk \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matthew@wil.cx \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®