All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 2/3] st.ko: remove unnecessary normalize_buffer
@ 2013-12-02 19:00 Bodo Stroesser
  0 siblings, 0 replies; 3+ messages in thread
From: Bodo Stroesser @ 2013-12-02 19:00 UTC (permalink / raw)
  To: linux-scsi; +Cc: kai.makisara, bstroesser

From: Bodo Stroesser <bstroesser@ts.fujitsu.com>
Date: Mon, 2 Dec 2013 18:52:10 +0100
Subject: [PATCH 2/3] st.ko: remove unnecessary normalize_buffer

This patch removes an unnecessary call to normalize_buffer()
in enlarge_buffer()

In st_open() always a buffer of one page is allocated.
When the buffer needs to be enlarged later, it does not make
sense to free this page unconditionally.
 
Cc: Kai Makisara <kai.makisara@kolumbus.fi>
Signed-off-by: Bodo Stroesser <bstroesser@ts.fujitsu.com>

---

--- a/drivers/scsi/st.c	2013-12-02 18:52:10.000000000 +0100
+++ b/drivers/scsi/st.c	2013-12-02 18:52:10.000000000 +0100
@@ -3725,9 +3725,6 @@ static int enlarge_buffer(struct st_buff
 	if (new_size <= STbuffer->buffer_size)
 		return 1;
 
-	if (STbuffer->buffer_size <= PAGE_SIZE)
-		normalize_buffer(STbuffer);  /* Avoid extra segment */
-
 	max_segs = STbuffer->use_sg;
 
 	priority = GFP_KERNEL | __GFP_NOWARN;

^ permalink raw reply	[flat|nested] 3+ messages in thread
[parent not found: <61eb00$4eu08m@dgate20u.abg.fsc.net>]

end of thread, other threads:[~2013-12-16 19:29 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-02 19:00 [PATCH 2/3] st.ko: remove unnecessary normalize_buffer Bodo Stroesser
     [not found] <61eb00$4eu08m@dgate20u.abg.fsc.net>
2013-12-16 18:45 ` "Kai Mäkisara (Kolumbus)"
2013-12-16 19:19   ` Strösser, Bodo

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.