Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1652232

[PATCH 1/1] - Fix reiserfs WARNING in dquot_writeback_dquots

Path csiph.com!news.redatomik.org!aioe.org!bofh.it!news.nic.it!robomod
From Tim Savannah <kata198@gmail.com>
Newsgroups linux.kernel
Subject [PATCH 1/1] - Fix reiserfs WARNING in dquot_writeback_dquots
Date Mon, 29 May 2017 07:00:02 +0200
Message-ID <tMkWC-3pg-7@gated-at.bofh.it> (permalink)
Dkim-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to:cc; bh=Rgfr55oRxv1ymY5Cmxp0IxQUueoycTI4FwpCgRRRMic=; b=jDHtcew4u5SlPpd7DgBFWiHA7esWcHFR4B1T7Vm7D+kZwSfQV9OeJz3QiZEMsHVOZT ywQMuvv4XNMnOh/CUi+OCJOHRXZE0YoTUG7+MPnjx43D/ePLjj0aUOuwt94KdnpVli93 PDqERYXYS08LI3t48jW9LuRGA6dDVrMC7zv2IItv+VS3a7WdX16OwVWM0qYlf37Hp4CW XZz2DKWCx/AurJ3v58bHnUTiDMXoXA8p1q/4RkJv9Sj3brAUT2vqMrPMd2DMDU9oxglC eAX+IgPKldIYBoChihUnxMaCAaEiDtgUUBNeAEVKZLbBVqKrnZ2Cj2w6WJj2vEr8GcKy jXAw==
X-Google-Dkim-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to:cc; bh=Rgfr55oRxv1ymY5Cmxp0IxQUueoycTI4FwpCgRRRMic=; b=US3pmpmvQ/4j5uqCwoavyCnNo5AbPdAc3N/1pv0mXGfKQBOmNJBOVLNmhJHu0OIFzi kkTvFFPHetASyOGjPsHjo9KCJRVkuwBmvlvLaCvmiToNdvFw+cRHWUMfHeWBwCOeS7om ovyspf+y4IFTTiPxb48WNUoLLNjjMOBSpp4eBjPdgIk97LoxgnUlHT1VuXB8keLvWEEt Ayx7wu8L5xCMfJv8aRLkKkc6lGGZhaU5fps9DLo/3uTaYcaMbT0HGDkbMGAbPp1CYH/G SwXkU5nO53qR1vusvgl7vsLuyh9n5h2x4mWqqDbiXugmqhp2qSuxDXj1j7ySiFGCqpKn BfPw==
X-Gm-Message-State AODbwcDQtMqyY2Q9UGuInWQ1qMhL4uixP1CzPOPTmhKnjTYtgG/c1ItJ 2tibAkgypmNwp3Gz/q0Qa47cjet9z0/8
X-Received by 10.129.162.142 with SMTP id z136mr10195303ywg.286.1496033835867; Sun, 28 May 2017 21:57:15 -0700 (PDT)
MIME-Version 1.0
Content-Type multipart/mixed; boundary="94eb2c114e9c5c84ac0550a2854d"
Sender robomod@news.nic.it
List-ID <linux-kernel.vger.kernel.org>
X-Mailing-List linux-kernel@vger.kernel.org
Approved robomod@news.nic.it
Lines 91
Organization linux.* mail to news gateway
X-Original-Cc linux-kernel@vger.kernel.org
X-Original-Date Mon, 29 May 2017 00:57:15 -0400
X-Original-Message-ID <CALxoUzv8NooVZmuZgXr1TiXrYqRx1TQ9GeOejJ2KvkNuiuPrUg@mail.gmail.com>
X-Original-Sender linux-kernel-owner@vger.kernel.org
Xref csiph.com linux.kernel:1652232

Show key headers only | View raw


[Multipart message — attachments visible in raw view] - view raw

Oops, sent last one without patch on accident. Attached this time.


This has been happening for me since 4.10

dquot_writeback_dquots expects a lock to be held on super_block->s_umount ,

and reiserfs_sync_fs, which calls dquot_writeback_dquots, does not
obtain such a lock.

Thus, the following warning is generated:

[Sun May 28 04:58:06 2017] ------------[ cut here ]------------
[Sun May 28 04:58:06 2017] WARNING: CPU: 0 PID: 31 at
fs/quota/dquot.c:620 dquot_writeback_dquots+0x248/0x250
[Sun May 28 04:58:06 2017] Modules linked in: bbswitch(O)
nls_iso8859_1 nls_cp437 iTCO_wdt iTCO_vendor_support acer_wmi
sparse_keymap coretemp efi_pstore hwmon intel_rapl
x86_pkg_temp_thermal intel_powerclamp pcspkr ath9k ath9k_common
ath9k_hw ath efivars mac80211 joydev psmouse i2c_i801 cfg80211
input_leds led_class nvidiafb vgastate fb_ddc atl1c i915
drm_kms_helper drm intel_gtt syscopyarea sysfillrect sysimgblt mei_me
fb_sys_fops i2c_algo_bit mei lpc_ich shpchp acpi_cpufreq thermal wmi
video tpm_tis tpm_tis_core button tpm sch_fq_codel evdev mac_hid
uvcvideo vboxnetflt(O) videobuf2_vmalloc videobuf2_memops
vboxnetadp(O) videobuf2_v4l2 videobuf2_core pci_stub videodev
vboxpci(O) media ath3k btusb btrtl btbcm btintel vboxdrv(O) bluetooth
rfkill loop usbip_host usbip_core sg ip_tables x_tables hid_generic
usbhid
[Sun May 28 04:58:06 2017]  hid sr_mod cdrom sd_mod serio_raw atkbd
libps2 ehci_pci xhci_pci ahci xhci_hcd ehci_hcd libahci libata
scsi_mod usbcore usb_common i8042 serio raid1 raid0 dm_mod md_mod
[Sun May 28 04:58:06 2017] CPU: 0 PID: 31 Comm: kworker/0:1 Tainted: G
          O    4.11.3-1-ck2-ck #1
[Sun May 28 04:58:06 2017] Hardware name: Acer Aspire V3-771/VA70_HC,
BIOS V2.16 01/14/2013
[Sun May 28 04:58:06 2017] Workqueue: events_long flush_old_commits
[Sun May 28 04:58:06 2017] Call Trace:
[Sun May 28 04:58:06 2017]  ? dump_stack+0x5c/0x7a
[Sun May 28 04:58:06 2017]  ? __warn+0xb4/0xd0
[Sun May 27 04:58:06 2017]  ? dquot_writeback_dquots+0x248/0x250
[Sun May 27 04:58:06 2017]  ? reiserfs_sync_fs+0x12/0x70
[Sun May 27 04:58:06 2017]  ? dbs_work_handler+0x3d/0x50
[Sun May 27 04:58:06 2017]  ? flush_old_commits+0x30/0x50
[Sun May 27 04:58:06 2017]  ? process_one_work+0x1b1/0x3a0
[Sun May 27 04:58:06 2017]  ? worker_thread+0x42/0x4c0
[Sun May 27 04:58:06 2017]  ? kthread+0xf2/0x130
[Sun May 27 04:58:06 2017]  ? process_one_work+0x3a0/0x3a0
[Sun May 27 04:58:06 2017]  ? kthread_create_on_node+0x40/0x40
[Sun May 27 04:58:06 2017]  ? ret_from_fork+0x26/0x40
[Sun May 27 04:58:06 2017] ---[ end trace 7e040d020ba99607 ]---


This occurs during system boot on a fully-updated Archlinux system,
and has so since 4.10 100% of the time. It may occur after as well,
but it's a WARN_ONCE.

The attached patch corrects this issue by first trying to obtain a
readlock on said structure member, and if it got it, releases it
before returning.

After applying the patch, my system is completely stable and the
warning no longer occurs. Mounting and unmounting works as expected
without issue.

Thanks,
- Tim Savannah

Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

[PATCH 1/1] - Fix reiserfs WARNING in dquot_writeback_dquots Tim Savannah <kata198@gmail.com> - 2017-05-29 07:00 +0200

csiph-web