linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chengguang Xu <cgxu519@mykernel.net>
To: "Pavel Machek" <pavel@denx.de>
Cc: "Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
	"linux-kernel" <linux-kernel@vger.kernel.org>,
	"stable" <stable@vger.kernel.org>, "Chao Yu" <yuchao0@huawei.com>,
	"Jaegeuk Kim" <jaegeuk@kernel.org>,
	"Sasha Levin" <sashal@kernel.org>
Subject: Re: [PATCH 4.19 062/114] f2fs: choose hardlimit when softlimit is larger than hardlimit in f2fs_statfs_project()
Date: Sat, 04 Jan 2020 09:50:43 +0800	[thread overview]
Message-ID: <16f6e3f5bbe.d291a05d38838.5222280714928609391@mykernel.net> (raw)
In-Reply-To: <20200103171213.GC14328@amd>

 ---- 在 星期六, 2020-01-04 01:12:13 Pavel Machek <pavel@denx.de> 撰写 ----
 > Hi!
 > 
 > > From: Chengguang Xu <cgxu519@mykernel.net>
 > > 
 > > [ Upstream commit 909110c060f22e65756659ec6fa957ae75777e00 ]
 > > 
 > > Setting softlimit larger than hardlimit seems meaningless
 > > for disk quota but currently it is allowed. In this case,
 > > there may be a bit of comfusion for users when they run
 > > df comamnd to directory which has project quota.
 > > 
 > > For example, we set 20M softlimit and 10M hardlimit of
 > > block usage limit for project quota of test_dir(project id 123).
 > 
 > > Signed-off-by: Chengguang Xu <cgxu519@mykernel.net>
 > > Reviewed-by: Chao Yu <yuchao0@huawei.com>
 > > Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
 > > Signed-off-by: Sasha Levin <sashal@kernel.org>
 > > ---
 > >  fs/f2fs/super.c | 20 ++++++++++++++------
 > >  1 file changed, 14 insertions(+), 6 deletions(-)
 > > 
 > > diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c
 > > index 7a9cc64f5ca3..662c7de58b99 100644
 > > --- a/fs/f2fs/super.c
 > > +++ b/fs/f2fs/super.c
 > > @@ -1148,9 +1148,13 @@ static int f2fs_statfs_project(struct super_block *sb,
 > >          return PTR_ERR(dquot);
 > >      spin_lock(&dquot->dq_dqb_lock);
 > >  
 > > -    limit = (dquot->dq_dqb.dqb_bsoftlimit ?
 > > -         dquot->dq_dqb.dqb_bsoftlimit :
 > > -         dquot->dq_dqb.dqb_bhardlimit) >> sb->s_blocksize_bits;
 > > +    limit = 0;
 > > +    if (dquot->dq_dqb.dqb_bsoftlimit)
 > > +        limit = dquot->dq_dqb.dqb_bsoftlimit;
 > > +    if (dquot->dq_dqb.dqb_bhardlimit &&
 > > +            (!limit || dquot->dq_dqb.dqb_bhardlimit < limit))
 > > +        limit = dquot->dq_dqb.dqb_bhardlimit;
 > > +
 > >      if (limit && buf->f_blocks > limit) {
 > 
 > >> blocksize disappeared here. That can't be right.
 > 
 > Plus, is this just obfuscated way of saying
 > 
 > limit = min_not_zero(dquot->dq_dqb.dqb_bsoftlimit, dquot->dq_dqb.dqb_bhardlimit)?
 > 

Please  skip this patch from  stable list,  I'll send  a revised patch to upstream.

Thanks.





  reply	other threads:[~2020-01-04  2:06 UTC|newest]

Thread overview: 134+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-02 22:06 [PATCH 4.19 000/114] 4.19.93-stable review Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 001/114] scsi: lpfc: Fix discovery failures when target device connectivity bounces Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 002/114] scsi: mpt3sas: Fix clear pending bit in ioctl status Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 003/114] scsi: lpfc: Fix locking on mailbox command completion Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 004/114] Input: atmel_mxt_ts - disable IRQ across suspend Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 005/114] f2fs: fix to update time in lazytime mode Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 006/114] iommu: rockchip: Free domain on .domain_free Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 007/114] iommu/tegra-smmu: Fix page tables in > 4 GiB memory Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 008/114] dmaengine: xilinx_dma: Clear desc_pendingcount in xilinx_dma_reset Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 009/114] scsi: target: compare full CHAP_A Algorithm strings Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 010/114] scsi: lpfc: Fix SLI3 hba in loop mode not discovering devices Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 011/114] scsi: csiostor: Dont enable IRQs too early Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 012/114] scsi: hisi_sas: Replace in_softirq() check in hisi_sas_task_exec() Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 013/114] powerpc/pseries: Mark accumulate_stolen_time() as notrace Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 014/114] powerpc/pseries: Dont fail hash page table insert for bolted mapping Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 015/114] powerpc/tools: Dont quote $objdump in scripts Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 016/114] dma-debug: add a schedule point in debug_dma_dump_mappings() Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 017/114] leds: lm3692x: Handle failure to probe the regulator Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 018/114] clocksource/drivers/asm9260: Add a check for of_clk_get Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 019/114] clocksource/drivers/timer-of: Use unique device name instead of timer Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 020/114] powerpc/security/book3s64: Report L1TF status in sysfs Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 021/114] powerpc/book3s64/hash: Add cond_resched to avoid soft lockup warning Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 022/114] ext4: update direct I/O read lock pattern for IOCB_NOWAIT Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 023/114] ext4: iomap that extends beyond EOF should be marked dirty Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 024/114] jbd2: Fix statistics for the number of logged blocks Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 025/114] scsi: tracing: Fix handling of TRANSFER LENGTH == 0 for READ(6) and WRITE(6) Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 026/114] scsi: lpfc: Fix duplicate unreg_rpi error in port offline flow Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 027/114] f2fs: fix to update dirs i_pino during cross_rename Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 028/114] clk: qcom: Allow constant ratio freq tables for rcg Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 029/114] clk: clk-gpio: propagate rate change to parent Greg Kroah-Hartman
2020-01-03  8:42   ` Pavel Machek
2020-01-02 22:06 ` [PATCH 4.19 030/114] irqchip/irq-bcm7038-l1: Enable parent IRQ if necessary Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 031/114] irqchip: ingenic: Error out if IRQ domain creation failed Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 032/114] mfd: mfd-core: Honour Device Trees request to disable a child-device Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 033/114] fs/quota: handle overflows of sysctl fs.quota.* and report as unsigned long Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 034/114] scsi: lpfc: fix: Coverity: lpfc_cmpl_els_rsp(): Null pointer dereferences Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 035/114] PCI: rpaphp: Fix up pointer to first drc-info entry Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 036/114] scsi: ufs: fix potential bug which ends in system hang Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 037/114] powerpc/pseries/cmm: Implement release() function for sysfs device Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 038/114] PCI: rpaphp: Dont rely on firmware feature to imply drc-info support Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 039/114] PCI: rpaphp: Annotate and correctly byte swap DRC properties Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 040/114] PCI: rpaphp: Correctly match ibm, my-drc-index to drc-name when using drc-info Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 041/114] powerpc/security: Fix wrong message when RFI Flush is disable Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 042/114] scsi: atari_scsi: sun3_scsi: Set sg_tablesize to 1 instead of SG_NONE Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 043/114] clk: pxa: fix one of the pxa RTC clocks Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 044/114] bcache: at least try to shrink 1 node in bch_mca_scan() Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 045/114] HID: quirks: Add quirk for HP MSU1465 PIXART OEM mouse Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 046/114] HID: logitech-hidpp: Silence intermittent get_battery_capacity errors Greg Kroah-Hartman
2020-01-02 22:06 ` [PATCH 4.19 047/114] ARM: 8937/1: spectre-v2: remove Brahma-B53 from hardening Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 048/114] libnvdimm/btt: fix variable rc set but not used Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 049/114] HID: Improve Windows Precision Touchpad detection Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 050/114] HID: rmi: Check that the RMI_STARTED bit is set before unregistering the RMI transport device Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 051/114] watchdog: Fix the race between the release of watchdog_core_data and cdev Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 052/114] scsi: pm80xx: Fix for SATA device discovery Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 053/114] scsi: ufs: Fix error handing during hibern8 enter Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 054/114] scsi: scsi_debug: num_tgts must be >= 0 Greg Kroah-Hartman
2020-01-03 16:34   ` Pavel Machek
2020-01-02 22:07 ` [PATCH 4.19 055/114] scsi: NCR5380: Add disconnect_mask module parameter Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 056/114] scsi: iscsi: Dont send data to unbound connection Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 057/114] scsi: target: iscsi: Wait for all commands to finish before freeing a session Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 058/114] gpio: mpc8xxx: Dont overwrite default irq_set_type callback Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 059/114] apparmor: fix unsigned len comparison with less than zero Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 060/114] scripts/kallsyms: fix definitely-lost memory leak Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 061/114] powerpc: Dont add -mabi= flags when building with Clang Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 062/114] f2fs: choose hardlimit when softlimit is larger than hardlimit in f2fs_statfs_project() Greg Kroah-Hartman
2020-01-03 17:12   ` Pavel Machek
2020-01-04  1:50     ` Chengguang Xu [this message]
2020-01-04 11:53       ` Greg Kroah-Hartman
2020-01-04 14:20         ` Chengguang Xu
2020-02-01  9:24         ` Chengguang Xu
2020-02-07 10:19           ` Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 063/114] cdrom: respect device capabilities during opening action Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 064/114] perf script: Fix brstackinsn for AUXTRACE Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 065/114] perf regs: Make perf_reg_name() return "unknown" instead of NULL Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 066/114] s390/zcrypt: handle new reply code FILTERED_BY_HYPERVISOR Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 067/114] libfdt: define INT32_MAX and UINT32_MAX in libfdt_env.h Greg Kroah-Hartman
2020-01-03 17:18   ` Pavel Machek
2020-01-02 22:07 ` [PATCH 4.19 068/114] s390/cpum_sf: Check for SDBT and SDB consistency Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 069/114] ocfs2: fix passing zero to PTR_ERR warning Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 070/114] mailbox: imx: Fix Tx doorbell shutdown path Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 071/114] kernel: sysctl: make drop_caches write-only Greg Kroah-Hartman
2020-01-03 18:29   ` Pavel Machek
2020-01-05 15:47     ` Sasha Levin
2020-01-02 22:07 ` [PATCH 4.19 072/114] userfaultfd: require CAP_SYS_PTRACE for UFFD_FEATURE_EVENT_FORK Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 073/114] Revert "powerpc/vcpu: Assume dedicated processors as non-preempt" Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 074/114] x86/mce: Fix possibly incorrect severity calculation on AMD Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 075/114] net, sysctl: Fix compiler warning when only cBPF is present Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 076/114] netfilter: nf_queue: enqueue skbs with NULL dst Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 077/114] ALSA: hda - Downgrade error message for single-cmd fallback Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 078/114] bonding: fix active-backup transition after link failure Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 079/114] perf strbuf: Remove redundant va_end() in strbuf_addv() Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 080/114] Make filldir[64]() verify the directory entry filename is valid Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 081/114] filldir[64]: remove WARN_ON_ONCE() for bad directory entries Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 082/114] PCI/switchtec: Read all 64 bits of part_event_bitmap Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 083/114] netfilter: ebtables: compat: reject all padding in matches/watchers Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 084/114] 6pack,mkiss: fix possible deadlock Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 085/114] netfilter: bridge: make sure to pull arp header in br_nf_forward_arp() Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 086/114] inetpeer: fix data-race in inet_putpeer / inet_putpeer Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 087/114] net: add a READ_ONCE() in skb_peek_tail() Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 088/114] net: icmp: fix data-race in cmp_global_allow() Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 089/114] hrtimer: Annotate lockless access to timer->state Greg Kroah-Hartman
2020-01-03 19:07   ` Pavel Machek
2020-01-02 22:07 ` [PATCH 4.19 090/114] net: ena: fix napi handler misbehavior when the napi budget is zero Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 091/114] net/mlxfw: Fix out-of-memory error in mfa2 flash burning Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 092/114] net: stmmac: dwmac-meson8b: Fix the RGMII TX delay on Meson8b/8m2 SoCs Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 093/114] ptp: fix the race between the release of ptp_clock and cdev Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 094/114] tcp: Fix highest_sack and highest_sack_seq Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 095/114] udp: fix integer overflow while computing available space in sk_rcvbuf Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 096/114] vhost/vsock: accept only packets with the right dst_cid Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 097/114] net: add bool confirm_neigh parameter for dst_ops.update_pmtu Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 098/114] ip6_gre: do not confirm neighbor when do pmtu update Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 099/114] gtp: " Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 100/114] net/dst: add new function skb_dst_update_pmtu_no_confirm Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 101/114] tunnel: do not confirm neighbor when do pmtu update Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 102/114] vti: " Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 103/114] sit: " Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 104/114] net/dst: do not confirm neighbor for vxlan and geneve " Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 105/114] gtp: do not allow adding duplicate tid and ms_addr pdp context Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 106/114] net: marvell: mvpp2: phylink requires the link interrupt Greg Kroah-Hartman
2020-01-02 22:07 ` [PATCH 4.19 107/114] tcp/dccp: fix possible race __inet_lookup_established() Greg Kroah-Hartman
2020-01-02 22:08 ` [PATCH 4.19 108/114] tcp: do not send empty skb from tcp_write_xmit() Greg Kroah-Hartman
2020-01-02 22:08 ` [PATCH 4.19 109/114] gtp: fix wrong condition in gtp_genl_dump_pdp() Greg Kroah-Hartman
2020-01-02 22:08 ` [PATCH 4.19 110/114] gtp: fix an use-after-free in ipv4_pdp_find() Greg Kroah-Hartman
2020-01-02 22:08 ` [PATCH 4.19 111/114] gtp: avoid zero size hashtable Greg Kroah-Hartman
2020-01-02 22:08 ` [PATCH 4.19 112/114] spi: fsl: dont map irq during probe Greg Kroah-Hartman
2020-01-02 22:08 ` [PATCH 4.19 113/114] tty/serial: atmel: fix out of range clock divider handling Greg Kroah-Hartman
2020-01-02 22:08 ` [PATCH 4.19 114/114] pinctrl: baytrail: Really serialize all register accesses Greg Kroah-Hartman
2020-01-03 14:27 ` [PATCH 4.19 000/114] 4.19.93-stable review Guenter Roeck
2020-01-03 15:41   ` Greg Kroah-Hartman
2020-01-03 17:46     ` Guenter Roeck
2020-01-04 12:32       ` Greg Kroah-Hartman
2020-01-04  4:32     ` Naresh Kamboju
2020-01-03 17:51 ` Jon Hunter
2020-01-03 21:55 ` shuah

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=16f6e3f5bbe.d291a05d38838.5222280714928609391@mykernel.net \
    --to=cgxu519@mykernel.net \
    --cc=gregkh@linuxfoundation.org \
    --cc=jaegeuk@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pavel@denx.de \
    --cc=sashal@kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=yuchao0@huawei.com \
    /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;
as well as URLs for NNTP newsgroup(s).