From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from cn.fujitsu.com ([222.73.24.84]:19436 "EHLO song.cn.fujitsu.com" rhost-flags-OK-FAIL-OK-OK) by vger.kernel.org with ESMTP id S1758658Ab3DYBMJ (ORCPT ); Wed, 24 Apr 2013 21:12:09 -0400 Message-ID: <5178826F.3040603@cn.fujitsu.com> Date: Thu, 25 Apr 2013 09:10:07 +0800 From: Gu Zheng MIME-Version: 1.0 To: Yinghai Lu CC: "linux-pci@vger.kernel.org" , Bjorn Helgaas , Yasuaki Ishimatsu , Taku Izumi , Jiang Liu , tangchen , Lin Feng Subject: Re: [PATCH 0/3] PCI: fix the object lifetime issue of parallel device removal on different pci hierarchy References: <516FB479.1060601@cn.fujitsu.com> <5177A782.5050603@cn.fujitsu.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-pci-owner@vger.kernel.org List-ID: On 04/25/2013 07:48 AM, Yinghai Lu wrote: > On Wed, Apr 24, 2013 at 10:11 AM, Yinghai Lu wrote: >> On Wed, Apr 24, 2013 at 2:36 AM, Gu Zheng wrote: >>> On 04/19/2013 03:43 AM, Yinghai Lu wrote: >> [...] >>>> I can not find where that reference count get reduced! >>>> in the my test patches that I sent, it does have have that in remove path. >>>> >>>> What is reason for you to remove that line? >>>> >>>> After put the line back, your test still can pass? >>> >>> Hi Yinghai, >>> The remove test script still can pass if we reduce the reference of pci_bus when destroying >>> the pci_dev, so does your patch, but a list_del corruption warning occurs in the bottom half routine: >> >> That is not clear. >> >> your patchset does not have list_del corruption warning? Hi Yinghai, Sorry for my unclear description, my patchset has the same warning. >> >>> ------------[ cut here ]------------ >>> WARNING: at lib/list_debug.c:53 __list_del_entry+0x63/0xd0() >>> Hardware name: PRIMEQUEST 1800E >>> list_del corruption, ffff8807d1b6c000->next is LIST_POISON1 (dead000000100100) >>> Modules linked in: shpchp ebtable_nat ebtables xt_CHECKSUM iptable_mangle bridge stp llc autofs4 sunrpc cpufreq_ondemand ipt_REJECT nf_conntrack_ipv4 nf_defrag_ipv4 iptable_filter ip_tables ip6t_REJECT nf_conntrack_ipv6 nf_defrag_ipv6 xt_state nf_conntrack ip6table_filter ip6_tables ipv6 vfat fat dm_mirror dm_region_hash dm_log dm_mod vhost_net macvtap macvlan tun uinput iTCO_wdt iTCO_vendor_support acpi_cpufreq freq_table mperf coretemp kvm_intel kvm crc32c_intel microcode pcspkr sg i2c_i801 lpc_ich mfd_core i7core_edac edac_core ioatdma e1000e igb dca i2c_algo_bit i2c_core ptp pps_core ext4(F) mbcache(F) jbd2(F) sd_mod(F) crc_t10dif(F) megaraid_sas(F) mptsas(F) mptscsih(F) mptbase(F) scsi_transport_sas(F) >>> Pid: 6, comm: kworker/u:0 Tainted: GF W 3.9.0-rc7-pci-remove-test+ #59 >>> Call Trace: >>> [] warn_slowpath_common+0x7f/0xc0 >>> [] warn_slowpath_fmt+0x46/0x50 >>> [] __list_del_entry+0x63/0xd0 >>> [] list_del+0x11/0x40 >>> [] pci_destroy_dev+0x31/0xc0 >>> [] pci_remove_bus_device+0x5b/0x70 >>> [] pci_stop_and_remove_bus_device+0x1e/0x30 >>> [] remove_callback+0x29/0x40 >>> [] sysfs_schedule_callback_work+0x24/0x70 >>> [] process_one_work+0x185/0x3f0 >>> [] worker_thread+0x119/0x380 >>> [] ? manage_workers+0x180/0x180 >>> [] kthread+0xce/0xe0 >>> [] ? kthread_freezable_should_stop+0x70/0x70 >>> [] ret_from_fork+0x7c/0xb0 >>> [] ? kthread_freezable_should_stop+0x70/0x70 >>> ---[ end trace 9c05e382f933a515 ]--- > > Attached patch on top of current linus tree should fix the racing problem. > > We don't need to bother to add get bus ref. etc. > > Let us know your test result. Thanks, I'll do the test soon, and send out the report later! Best regards, Gu > > Yinghai