login
Login
/
Register
Search
Search this site:
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-ext4
»
2010
»
May
»
14
Re: [PATCH, RFC] support discard in non-journal ext4
view
thread
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From: Jiaying Zhang
Subject:
Re: [PATCH, RFC] support discard in non-journal ext4
Date: Thursday, May 13, 2010 - 5:29 pm
On Thu, May 13, 2010 at 2:08 AM, Coly Li <coly.li@suse.de> wrote:
quoted text
> > > On 05/13/2010 01:00 PM, Jiaying Zhang Wrote: > > This patch issues discard request for freed blocks in ext4_free_blocks() > > if ext4 is mounted with discard option and without journal. > > > > Author: Jiaying Zhang <jiayingz@google.com> > > Date: Wed May 12 21:11:46 2010 -0700 > > > > Issue discard request in ext4_free_blocks() when ext4 has no journal and > > is mounted with discard option. > > > > Signed-off-by: Jiaying Zhang <jiayingz@google.com> > > > > diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c > > index a291cc3..d51b79a 100644 > > --- a/fs/ext4/mballoc.c > > +++ b/fs/ext4/mballoc.c > > @@ -2513,6 +2513,22 @@ int ext4_mb_release(struct super_block *sb) > > return 0; > > } > > > > +static void ext4_issue_discard(struct super_block *sb, ext4_group_t block_group, > > + ext4_grpblk_t block, int count) > > +{ > > + int ret; > > + ext4_fsblk_t discard_block; > > + > > + discard_block = block + ext4_group_first_block_no(sb, block_group); > > + trace_ext4_discard_blocks(sb, > > + (unsigned long long) discard_block, count); > > + ret = sb_issue_discard(sb, discard_block, count); > > + if (ret == EOPNOTSUPP) { > > + ext4_warning(sb, "discard not supported, disabling"); > > + clear_opt(EXT4_SB(sb)->s_mount_opt, DISCARD); > > + } > > +} > > + > > How about make it as an inline routine? Thanks.
Ok. I changed it to inline. The modified patch is attached. Thanks! Jiaying
quoted text
> > -- > Coly Li > SuSE Labs
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
Messages in current thread:
[PATCH, RFC] support discard in non-journal ext4
, Jiaying Zhang
, (Wed May 12, 10:00 pm)
Re: [PATCH, RFC] support discard in non-journal ext4
, Coly Li
, (Thu May 13, 2:08 am)
Re: [PATCH, RFC] support discard in non-journal ext4
, Jiaying Zhang
, (Thu May 13, 5:29 pm)
Re: [PATCH, RFC] support discard in non-journal ext4
, Coly Li
, (Thu May 13, 9:03 pm)
Re: [PATCH, RFC] support discard in non-journal ext4
, Coly Li
, (Thu May 13, 9:09 pm)
Navigation
Create content
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Trent Waddington
Re: Gaming Interface
Takashi Iwai
Re: [PATCH] usb: usbmixer error path fix
Jeremy Fitzhardinge
Re: [patch 1/6] Re-enable VDSO by default with PARAVIRT
Paul E. McKenney
Re: [PATCH, RFC] v4 scalable classic RCU implementation
Greg Kroah-Hartman
[PATCH 20/36] Driver core: Call device_pm_add() after bus_add_device() in device_a...
git
:
Stephen R. van den Berg
Re: [RFC] origin link for cherry-pick and revert
Christian Stimming
git-gui: Fix broken revert confirmation.
Junio C Hamano
Re: git-svnimport
Mark Burton
Re: [PATCH] builtin-branch: highlight current remote branches with an asterisk
Johannes Schindelin
Re: [PATCH] Fix approxidate("never") to always return 0
git-commits-head
:
Linux Kernel Mailing List
ath9k_htc: Allocate URBs properly
Linux Kernel Mailing List
bnx2x: Fan failure mechanism on additional design
Linux Kernel Mailing List
cpumask: make irq_set_affinity() take a const struct cpumask
Linux Kernel Mailing List
ARM: 5670/1: bcmring: add default configuration for bcmring arch
Linux Kernel Mailing List
ahci: Workaround HW bug for SB600/700 SATA controller PMP support
linux-netdev
:
Nick Piggin
Re: Kernel WARNING: at net/core/dev.c:1330 __netif_schedule+0x2c/0x98()
Daniel Lezcano
getsockopt(TCP_DEFER_ACCEPT) value change
David Miller
Re: 2.6.27.18: bnx2/tg3: BUG: "scheduling while atomic" trying to ifenslave a seco...
Amit Kumar Salecha
[PATCH NEXT 10/10] qlcnic: add cksum flag
Ingo Molnar
Re: [regression] nf_iterate(), BUG: unable to handle kernel NULL pointer dereference
openbsd-misc
:
James Hozier
Re: DVD burn error: No space left on device
Christophe Rioux
Implementation example of snmp
Ryan McBride
Re: Packets Per Second Limit?
Nick Holland
Re: booting openbsd on eee without cd-rom
Very Fashion.com
Very-fashion.com -Novo! Brendirana garderoba po najpovoljnijim cenama.Bisou Bisou ...
Colocation donated by:
Syndicate