1. 23 6月, 2015 4 次提交
    • G
      rocker: call correct unregister function on error · a076e6bf
      Gilad Ben-Yossef 提交于
      Use the correct unregister function matching the register
      function on the error path.
      Signed-off-by: NGilad Ben-Yossef <gilad@benyossef.com>
      Fixes: c1beeef7 ("rocker: implement IPv4 fib offloading")
      Acked-by: NJiri Pirko <jiri@resnulli.us>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a076e6bf
    • A
      net: fs_enet: Fix NETIF_F_SG feature for Freescale MPC5121 · 26c0a14f
      Alexander Popov 提交于
      Commit 4fc9b87b ("net: fs_enet: Implement NETIF_F_SG feature")
      brings a trouble to Freescale MPC512x: a kernel oops happens
      during sending non-linear sk_buff with .data not aligned by 4.
      
      Log quotation:
      
      Unable to handle kernel paging request for data at address 0xe467c000
      Faulting instruction address: 0xc000cd44
      Oops: Kernel access of bad area, sig: 11 [#1]
      MPC512x generic
      Modules linked in:
      CPU: 0 PID: 984 Comm: kworker/0:1H Not tainted 4.1.0-rc8-00024-gbb16140a #2
      Workqueue: rpciod rpc_async_schedule
      task: cf364a50 ti: cf362000 task.ti: cf362000
      NIP: c000cd44 LR: c000c720 CTR: 00000206
      REGS: cf363ac0 TRAP: 0300   Not tainted  (4.1.0-rc8-00024-gbb16140a)
      MSR: 00009032 <EE,ME,IR,DR,RI>  CR: 42004082  XER: 00000000
      DAR: e467c000 DSISR: 20000000
      GPR00: c0279e24 cf363b70 cf364a50 e467c000 00000206 0000001f 00000001 00000001
      GPR08: 00000000 e467c000 e46800be 000139a6 82002082 00000000 c002e46c cf3c3680
      GPR16: c044cb30 c04b0000 cf363c48 00000000 00000001 fde0315c 00000000 0000000b
      GPR24: 0000002c 000040be cf339aa0 0000000b 00000001 cf873210 00282f85 00000000
      NIP [c000cd44] clean_dcache_range+0x1c/0x30
      LR [c000c720] dma_direct_map_page+0x40/0x94
      Call Trace:
      [cf363b70] [cf339b60] 0xcf339b60 (unreliable)
      [cf363b90] [c0279e24] fs_enet_start_xmit+0x1c8/0x42c
      [cf363bd0] [c02ff710] dev_hard_start_xmit+0x2dc/0x3d4
      [cf363c40] [c0319c60] sch_direct_xmit+0xcc/0x1cc
      [cf363c70] [c02ff9c0] __dev_queue_xmit+0x1b8/0x47c
      [cf363ca0] [c032a3e8] ip_finish_output+0x1fc/0x9a8
      [cf363ce0] [c032c31c] ip_send_skb+0x1c/0xa4
      [cf363cf0] [c035112c] udp_send_skb+0xe4/0x2e8
      [cf363d10] [c0351368] udp_push_pending_frames+0x38/0x84
      [cf363d20] [c03537b8] udp_sendpage+0x134/0x174
      [cf363d70] [c0384fd4] xs_sendpages+0x21c/0x250
      [cf363db0] [c03852bc] xs_udp_send_request+0x50/0xf8
      [cf363de0] [c0382f08] xprt_transmit+0x64/0x280
      [cf363e20] [c038017c] call_transmit+0x168/0x234
      [cf363e40] [c0387918] __rpc_execute+0x88/0x2b0
      [cf363e80] [c00296f8] process_one_work+0x124/0x2fc
      [cf363ea0] [c0029a00] worker_thread+0x130/0x480
      [cf363ef0] [c002e528] kthread+0xbc/0xd0
      [cf363f40] [c000e4a8] ret_from_kernel_thread+0x5c/0x64
      Instruction dump:
      7c70faa6 60630800 7c70fba6 4c00012c 4e800020 38a0001f 7c632878 7c832050
      7c842a14 5484d97f 4d820020 7c8903a6 <7c00186c> 38630020 4200fff8 7c0004ac
      ---[ end trace c846c1eceb513c85 ]---
      
      The reason:
      
      MPC5121 FEC requires 4-byte alignment for TX data buffer and calls
      tx_skb_align_workaround() for copying sk_buff with not aligned .data to a new
      sk_buff with aligned one. But tx_skb_align_workaround() uses
      skb_copy_from_linear_data() which doesn't work for non-linear sk_buff:
      a new sk_buff has non-zero nr_frags and zero .data_len.
      
      So improve the condition of calling tx_skb_align_workaround() and use
      skb_linearize() in it.
      Signed-off-by: NAlexander Popov <alex.popov@linux.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      26c0a14f
    • P
      xen-netback: fix a BUG() during initialization · 12b322ac
      Palik, Imre 提交于
      Commit edafc132 ("xen-netback: making the bandwidth limiter runtime settable")
      introduced the capability to change the bandwidth rate limit at runtime.
      But it also introduced a possible crashing bug.
      
      If netback receives two XenbusStateConnected without getting the
      hotplug-status watch firing in between, then it will try to register the
      watches for the rate limiter again.  But this triggers a BUG() in the watch
      registration code.
      
      The fix modifies connect() to remove the possibly existing packet-rate
      watches before trying to install those watches.  This behaviour is in line
      with how connect() deals with the hotplug-status watch.
      Signed-off-by: NImre Palik <imrep@amazon.de>
      Cc: Matt Wilson <msw@amazon.com>
      Acked-by: NWei Liu <wei.liu2@citrix.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      12b322ac
    • S
      mvneta: add forgotten initialization of autonegotiation bits · 538761b7
      Stas Sergeev 提交于
      The commit 898b2970 ("mvneta: implement SGMII-based in-band link state
      signaling")
      changed mvneta_adjust_link() so that it does not clear the auto-negotiation
      bits in MVNETA_GMAC_AUTONEG_CONFIG register. This was necessary for
      auto-negotiation mode to work.
      Unfortunately I haven't checked if these bits are ever initialized.
      It appears they are not.
      This patch adds the missing initialization of the auto-negotiation bits
      in the MVNETA_GMAC_AUTONEG_CONFIG register.
      It fixes the following regression:
      https://www.mail-archive.com/netdev@vger.kernel.org/msg67928.html
      
      Since the patch was tested to fix a regression, it should be applied to
      stable tree.
      Tested-by: NArnaud Ebalard <arno@natisbad.org>
      
      CC: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
      CC: Florian Fainelli <f.fainelli@gmail.com>
      CC: netdev@vger.kernel.org
      CC: linux-kernel@vger.kernel.org
      CC: stable@vger.kernel.org
      Signed-off-by: NStas Sergeev <stsp@users.sourceforge.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      538761b7
  2. 22 6月, 2015 2 次提交
  3. 16 6月, 2015 1 次提交
  4. 12 6月, 2015 6 次提交
    • D
      iommu/vt-d: Only enable extended context tables if PASID is supported · c83b2f20
      David Woodhouse 提交于
      Although the extended tables are theoretically a completely orthogonal
      feature to PASID and anything else that *uses* the newly-available bits,
      some of the early hardware has problems even when all we do is enable
      them and use only the same bits that were in the old context tables.
      
      For now, there's no motivation to support extended tables unless we're
      going to use PASID support to do SVM. So just don't use them unless
      PASID support is advertised too. Also add a command-line bailout just in
      case later chips also have issues.
      
      The equivalent problem for PASID support has already been fixed with the
      upcoming VT-d spec update and commit bd00c606 ("iommu/vt-d: Change
      PASID support to bit 40 of Extended Capability Register"), because the
      problematic platforms use the old definition of the PASID-capable bit,
      which is now marked as reserved and meaningless.
      
      So with this change, we'll magically start using ECS again only when we
      see the new hardware advertising "hey, we have PASID support and we
      actually tested it this time" on bit 40.
      
      The VT-d hardware architect has promised that we are not going to have
      any reason to support ECS *without* PASID any time soon, and he'll make
      sure he checks with us before changing that.
      
      In the future, if hypothetical new features also use new bits in the
      context tables and can be seen on implementations *without* PASID support,
      we might need to add their feature bits to the ecs_enabled() macro.
      Signed-off-by: NDavid Woodhouse <David.Woodhouse@intel.com>
      c83b2f20
    • N
      md: make sure MD_RECOVERY_DONE is clear before starting recovery/resync · ea358cd0
      NeilBrown 提交于
      MD_RECOVERY_DONE is normally cleared by md_check_recovery after a
      resync etc finished.  However it is possible for raid5_start_reshape
      to race and start a reshape before MD_RECOVERY_DONE is cleared.  This
      can lean to multiple reshapes running at the same time, which isn't
      good.
      
      To make sure it is cleared before starting a reshape, and also clear
      it when reaping a thread, just to be safe.
      Signed-off-by: NNeilBrown  <neilb@suse.de>
      ea358cd0
    • N
      md: Close race when setting 'action' to 'idle'. · 8e8e2518
      NeilBrown 提交于
      Checking ->sync_thread without holding the mddev_lock()
      isn't really safe, even after flushing the workqueue which
      ensures md_start_sync() has been run.
      
      While this code is waiting for the lock, md_check_recovery could reap
      the thread itself, and then start another thread (e.g. recovery might
      finish, then reshape starts).  When this thread gets the lock
      md_start_sync() hasn't run so it doesn't get reaped, but
      MD_RECOVERY_RUNNING gets cleared.  This allows two threads to start
      which leads to confusion.
      
      So don't both if MD_RECOVERY_RUNNING isn't set, but if it is do
      the flush and the test and the reap all under the mddev_lock to
      avoid any race with md_check_recovery.
      Signed-off-by: NNeilBrown <neilb@suse.de>
      Fixes: 6791875e ("md: make reconfig_mutex optional for writes to md sysfs files.")
      Cc: stable@vger.kernel.org (v4.0+)
      8e8e2518
    • N
      md: don't return 0 from array_state_store · c008f1d3
      NeilBrown 提交于
      Returning zero from a 'store' function is bad.
      The return value should be either len length of the string
      or an error.
      
      So use 'len' if 'err' is zero.
      
      Fixes: 6791875e ("md: make reconfig_mutex optional for writes to md sysfs files.")
      Signed-off-by: NNeilBrown <neilb@suse.de>
      Cc: stable@vger.kernel (v4.0+)
      c008f1d3
    • R
      net: igb: fix the start time for periodic output signals · 58c98be1
      Richard Cochran 提交于
      When programming the start of a periodic output, the code wrongly places
      the seconds value into the "low" register and the nanoseconds into the
      "high" register.  Even though this is backwards, it slipped through my
      testing, because the re-arming code in the interrupt service routine is
      correct, and the signal does appear starting with the second edge.
      
      This patch fixes the issue by programming the registers correctly.
      Signed-off-by: NRichard Cochran <richardcochran@gmail.com>
      Reviewed-by: NJacob Keller <jacob.e.keller@intel.com>
      Acked-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      58c98be1
    • R
      block: pmem: Add dependency on HAS_IOMEM · b6f2098f
      Richard Weinberger 提交于
      Not all architectures have io memory.
      
      Fixes:
      drivers/block/pmem.c: In function ‘pmem_alloc’:
      drivers/block/pmem.c:146:2: error: implicit declaration of function ‘ioremap_nocache’ [-Werror=implicit-function-declaration]
        pmem->virt_addr = ioremap_nocache(pmem->phys_addr, pmem->size);
        ^
      drivers/block/pmem.c:146:18: warning: assignment makes pointer from integer without a cast [enabled by default]
        pmem->virt_addr = ioremap_nocache(pmem->phys_addr, pmem->size);
                        ^
      drivers/block/pmem.c:182:2: error: implicit declaration of function ‘iounmap’ [-Werror=implicit-function-declaration]
        iounmap(pmem->virt_addr);
        ^
      Signed-off-by: NRichard Weinberger <richard@nod.at>
      Reviewed-by: NRoss Zwisler <ross.zwisler@linux.intel.com>
      Signed-off-by: NJens Axboe <axboe@fb.com>
      b6f2098f
  5. 11 6月, 2015 8 次提交
    • M
      drm/radeon: Make sure radeon_vm_bo_set_addr always unreserves the BO · ee18e599
      Michel Dänzer 提交于
      Some error paths didn't unreserve the BO. This resulted in a deadlock
      down the road on the next attempt to reserve the (still reserved) BO.
      
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=90873
      Cc: stable@vger.kernel.org
      Reviewed-by: NChristian König <christian.koenig@amd.com>
      Signed-off-by: NMichel Dänzer <michel.daenzer@amd.com>
      Signed-off-by: NAlex Deucher <alexander.deucher@amd.com>
      ee18e599
    • A
      Revert "drm/radeon: adjust pll when audio is not enabled" · ebb9bf18
      Alex Deucher 提交于
      This reverts commit 7fe04d6f.
      
      Fixes some systems at the expense of others.  Need to properly
      fix the pll divider selection.
      
      bug:
      https://bugzilla.kernel.org/show_bug.cgi?id=99651
      
      Cc: stable@vger.kernel.org
      ebb9bf18
    • A
      Revert "drm/radeon: don't share plls if monitors differ in audio support" · 6fb3c025
      Alex Deucher 提交于
      This reverts commit a10f0df0.
      
      Fixes some systems at the expense of others.  Need to properly
      fix the pll divider selection.
      
      bug:
      https://bugzilla.kernel.org/show_bug.cgi?id=99651
      
      Cc: stable@vger.kernel.org
      6fb3c025
    • J
      drm/radeon: fix freeze for laptop with Turks/Thames GPU. · 6dfd1972
      Jérôme Glisse 提交于
      Laptop with Turks/Thames GPU will freeze if dpm is enabled. It seems
      the SMC engine is relying on some state inside the CP engine. CP needs
      to chew at least one packet for it to get in good state for dynamic
      power management.
      
      This patch simply disabled and re-enable DPM after the ring test which
      is enough to avoid the freeze.
      Signed-off-by: NJérôme Glisse <jglisse@redhat.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: NAlex Deucher <alexander.deucher@amd.com>
      6dfd1972
    • G
      enic: fix memory leak in rq_clean · 8b13b4e0
      Govindarajulu Varadarajan 提交于
      When incoming packet qualifies for rx_copybreak, we copy the data to newly
      allocated skb. We do not free/unmap the original buffer. At this point driver
      assumes this buffer is unallocated. When enic_rq_alloc_buf() is called for
      buffer allocation, it checks if buf->os_buf is NULL. If its not NULL that means
      buffer can be re-used.
      
      When vnic_rq_clean() is called for freeing all rq buffers, and if the
      rx_copybreak reused buffer falls outside the used desc, we do not free the
      buffer. The following trace is observer when dma-debug is enabled.
      
      Fix is to walk through complete ring and clean if buffer is present.
      
      [   40.555386] ------------[ cut here ]------------
      [   40.555396] WARNING: CPU: 0 PID: 491 at lib/dma-debug.c:971 dma_debug_device_change+0x188/0x1f0()
      [   40.555400] pci 0000:06:00.0: DMA-API: device driver has pending DMA allocations while released from device [count=4]
                     One of leaked entries details: [device address=0x00000000ff4cc040] [size=9018 bytes] [mapped with DMA_FROM_DEVICE] [mapped as single]
      [   40.555402] Modules linked in: nfsv3 nfs_acl rpcsec_gss_krb5 auth_rpcgss oid_registry nfsv4 dns_resolver coretemp intel_rapl iosf_mbi x86_pkg_temp_thermal intel_powerclamp kvm_intel kvm crct10dif_pclmul crc32_pclmul ghash_clmulni_intel aesni_intel aes_x86_64 lrw joydev mousedev gf128mul hid_generic glue_helper mgag200 usbhid ttm hid drm_kms_helper drm ablk_helper syscopyarea sysfillrect sysimgblt i2c_algo_bit i2c_core iTCO_wdt cryptd mac_hid evdev pcspkr sb_edac edac_core tpm_tis iTCO_vendor_support ipmi_si wmi tpm ipmi_msghandler shpchp lpc_ich processor acpi_power_meter hwmon button ac sch_fq_codel nfs lockd grace sunrpc fscache sd_mod ehci_pci ehci_hcd megaraid_sas usbcore scsi_mod usb_common enic(-) crc32c_generic crc32c_intel btrfs xor raid6_pq ext4 crc16 mbcache jbd2
      [   40.555467] CPU: 0 PID: 491 Comm: rmmod Not tainted 4.1.0-rc7-ARCH-01305-gf59b71f #118
      [   40.555469] Hardware name: Cisco Systems Inc UCSB-B200-M4/UCSB-B200-M4, BIOS B200M4.2.2.2.23.061220140128 06/12/2014
      [   40.555471]  0000000000000000 00000000e2f8a5b7 ffff880275f8bc48 ffffffff8158d6f0
      [   40.555474]  0000000000000000 ffff880275f8bca0 ffff880275f8bc88 ffffffff8107b04a
      [   40.555477]  ffff8802734e0000 0000000000000004 ffff8804763fb3c0 ffff88027600b650
      [   40.555480] Call Trace:
      [   40.555488]  [<ffffffff8158d6f0>] dump_stack+0x4f/0x7b
      [   40.555492]  [<ffffffff8107b04a>] warn_slowpath_common+0x8a/0xc0
      [   40.555494]  [<ffffffff8107b0d5>] warn_slowpath_fmt+0x55/0x70
      [   40.555498]  [<ffffffff812fa408>] dma_debug_device_change+0x188/0x1f0
      [   40.555503]  [<ffffffff8109aaef>] notifier_call_chain+0x4f/0x80
      [   40.555506]  [<ffffffff8109aecb>] __blocking_notifier_call_chain+0x4b/0x70
      [   40.555510]  [<ffffffff8109af06>] blocking_notifier_call_chain+0x16/0x20
      [   40.555514]  [<ffffffff813f8066>] __device_release_driver+0xf6/0x120
      [   40.555518]  [<ffffffff813f8b08>] driver_detach+0xc8/0xd0
      [   40.555523]  [<ffffffff813f7c59>] bus_remove_driver+0x59/0xe0
      [   40.555527]  [<ffffffff813f93a0>] driver_unregister+0x30/0x70
      [   40.555534]  [<ffffffff8131532d>] pci_unregister_driver+0x2d/0xa0
      [   40.555542]  [<ffffffffa0200ec2>] enic_cleanup_module+0x10/0x14e [enic]
      [   40.555547]  [<ffffffff8110158f>] SyS_delete_module+0x1cf/0x280
      [   40.555551]  [<ffffffff811e284e>] ? ____fput+0xe/0x10
      [   40.555554]  [<ffffffff810980ec>] ? task_work_run+0xbc/0xf0
      [   40.555558]  [<ffffffff815930ee>] system_call_fastpath+0x12/0x71
      [   40.555561] ---[ end trace 4988cadc77c2b236 ]---
      [   40.555562] Mapped at:
      [   40.555563]  [<ffffffff812fa865>] debug_dma_map_page+0x95/0x150
      [   40.555566]  [<ffffffffa01f4a88>] enic_rq_alloc_buf+0x1b8/0x360 [enic]
      [   40.555570]  [<ffffffffa01f7658>] enic_open+0xf8/0x820 [enic]
      [   40.555574]  [<ffffffff8148d50e>] __dev_open+0xce/0x150
      [   40.555579]  [<ffffffff8148d851>] __dev_change_flags+0xa1/0x170
      Signed-off-by: NGovindarajulu Varadarajan <_govind@gmx.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      8b13b4e0
    • G
      enic: check return value for stat dump · 19b596bd
      Govindarajulu Varadarajan 提交于
      We do not check the return value of enic_dev_stats_dump(). If allocation
      fails, we will hit NULL pointer reference.
      
      Return only if memory allocation fails. For other failures, we return the
      previously recorded values.
      Signed-off-by: NGovindarajulu Varadarajan <_govind@gmx.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      19b596bd
    • G
      enic: unlock napi busy poll before unmasking intr · 6286e828
      Govindarajulu Varadarajan 提交于
      There is a small window between vnic_intr_unmask() and enic_poll_unlock_napi().
      In this window if an irq occurs and napi is scheduled on different cpu, it tries
      to acquire enic_poll_lock_napi() and hits the following WARN_ON message.
      
      Fix is to unlock napi_poll before unmasking the interrupt.
      
      [  781.121746] ------------[ cut here ]------------
      [  781.121789] WARNING: CPU: 1 PID: 0 at drivers/net/ethernet/cisco/enic/vnic_rq.h:228 enic_poll_msix_rq+0x36a/0x3c0 [enic]()
      [  781.121834] Modules linked in: nfsv3 nfs_acl rpcsec_gss_krb5 auth_rpcgss oid_registry nfsv4 dns_resolver coretemp intel_rapl iosf_mbi x86_pkg_temp_thermal intel_powerclamp kvm_intel kvm crct10dif_pclmul crc32_pclmul ghash_clmulni_intel aesni_intel mgag200 ttm drm_kms_helper joydev aes_x86_64 lrw drm gf128mul mousedev glue_helper sb_edac ablk_helper iTCO_wdt iTCO_vendor_support evdev ipmi_si syscopyarea sysfillrect sysimgblt i2c_algo_bit i2c_core edac_core lpc_ich mac_hid cryptd pcspkr ipmi_msghandler shpchp tpm_tis acpi_power_meter tpm wmi processor hwmon button ac sch_fq_codel nfs lockd grace sunrpc fscache hid_generic usbhid hid ehci_pci ehci_hcd sd_mod megaraid_sas usbcore scsi_mod usb_common enic crc32c_generic crc32c_intel btrfs xor raid6_pq ext4 crc16 mbcache jbd2
      [  781.122176] CPU: 1 PID: 0 Comm: swapper/1 Not tainted 4.1.0-rc6-ARCH-00040-gc46a024e-dirty #106
      [  781.122210] Hardware name: Cisco Systems Inc UCSB-B200-M4/UCSB-B200-M4, BIOS B200M4.2.2.2.23.061220140128 06/12/2014
      [  781.122252]  0000000000000000 bddbbc9d655ec96e ffff880277e43da8 ffffffff81583fe8
      [  781.122286]  0000000000000000 0000000000000000 ffff880277e43de8 ffffffff8107acfa
      [  781.122319]  ffff880272c01000 ffff880273f18000 ffff880273f1a100 0000000000000000
      [  781.122352] Call Trace:
      [  781.122364]  <IRQ>  [<ffffffff81583fe8>] dump_stack+0x4f/0x7b
      [  781.122399]  [<ffffffff8107acfa>] warn_slowpath_common+0x8a/0xc0
      [  781.122425]  [<ffffffff8107ae2a>] warn_slowpath_null+0x1a/0x20
      [  781.122455]  [<ffffffffa01fa9ca>] enic_poll_msix_rq+0x36a/0x3c0 [enic]
      [  781.122487]  [<ffffffff8148525a>] net_rx_action+0x22a/0x370
      [  781.122512]  [<ffffffff8107ed3d>] __do_softirq+0xed/0x2d0
      [  781.122537]  [<ffffffff8107f06e>] irq_exit+0x7e/0xa0
      [  781.122560]  [<ffffffff8158c424>] do_IRQ+0x64/0x100
      [  781.122582]  [<ffffffff8158a42e>] common_interrupt+0x6e/0x6e
      [  781.122605]  <EOI>  [<ffffffff810bd331>] ? cpu_startup_entry+0x121/0x480
      [  781.122638]  [<ffffffff810bd2fc>] ? cpu_startup_entry+0xec/0x480
      [  781.122667]  [<ffffffff810f2ed3>] ? clockevents_register_device+0x113/0x1f0
      [  781.122698]  [<ffffffff81050ab6>] start_secondary+0x196/0x1e0
      [  781.122723] ---[ end trace cec2e9dd3af7b9db ]---
      Signed-off-by: NGovindarajulu Varadarajan <_govind@gmx.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      6286e828
    • W
      zram: clear disk io accounting when reset zram device · d7ad41a1
      Weijie Yang 提交于
      Clear zram disk io accounting when resetting the zram device.  Otherwise
      the residual io accounting stat will affect the diskstat in the next
      zram active cycle.
      Signed-off-by: NWeijie Yang <weijie.yang@samsung.com>
      Acked-by: NSergey Senozhatsky <sergey.senozhatsky@gmail.com>
      Acked-by: NMinchan Kim <minchan@kernel.org>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      d7ad41a1
  6. 09 6月, 2015 3 次提交
    • J
      drm/i915: Fix DDC probe for passive adapters · 3f5f1554
      Jani Nikula 提交于
      Passive DP->DVI/HDMI dongles on DP++ ports show up to the system as HDMI
      devices, as they do not have a sink device in them to respond to any AUX
      traffic. When probing these dongles over the DDC, sometimes they will
      NAK the first attempt even though the transaction is valid and they
      support the DDC protocol. The retry loop inside of
      drm_do_probe_ddc_edid() would normally catch this case and try the
      transaction again, resulting in success.
      
      That, however, was thwarted by the fix for [1]:
      
      commit 9292f37e
      Author: Eugeni Dodonov <eugeni.dodonov@intel.com>
      Date:   Thu Jan 5 09:34:28 2012 -0200
      
          drm: give up on edid retries when i2c bus is not responding
      
      This added code to exit immediately if the return code from the
      i2c_transfer function was -ENXIO in order to reduce the amount of time
      spent in waiting for unresponsive or disconnected devices. That was
      possible because the underlying i2c bit banging algorithm had retries of
      its own (which, of course, were part of the reason for the bug the
      commit fixes).
      
      Since its introduction in
      
      commit f899fc64
      Author: Chris Wilson <chris@chris-wilson.co.uk>
      Date:   Tue Jul 20 15:44:45 2010 -0700
      
          drm/i915: use GMBUS to manage i2c links
      
      we've been flipping back and forth enabling the GMBUS transfers, but
      we've settled since then. The GMBUS implementation does not do any
      retries, however, bailing out of the drm_do_probe_ddc_edid() retry loop
      on first encounter of -ENXIO. This, combined with Eugeni's commit, broke
      the retry on -ENXIO.
      
      Retry GMBUS once on -ENXIO on first message to mitigate the issues with
      passive adapters.
      
      This patch is based on the work, and commit message, by Todd Previte
      <tprevite@gmail.com>.
      
      [1] https://bugs.freedesktop.org/show_bug.cgi?id=41059
      
      v2: Don't retry if using bit banging.
      
      v3: Move retry within gmbux_xfer, retry only on first message.
      
      v4: Initialize GMBUS0 on retry (Ville).
      
      v5: Take index reads into account (Ville).
      
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=85924
      Cc: Todd Previte <tprevite@gmail.com>
      Cc: stable@vger.kernel.org
      Tested-by: Oliver Grafe <oliver.grafe@ge.com> (v2)
      Tested-by: NJim Bride <jim.bride@linux.intel.com>
      Reviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Signed-off-by: NJani Nikula <jani.nikula@intel.com>
      3f5f1554
    • F
      net: bcmgenet: power on MII block for all MII modes · afe3f907
      Florian Fainelli 提交于
      The RGMII block is currently only powered on when using RGMII or
      RGMII_NO_ID, which is not correct when using the GENET interface in MII
      or Reverse MII modes. We always need to power on the RGMII interface for
      this block to properly work, regardless of the MII mode in which we
      operate.
      
      Fixes: aa09677c ("net: bcmgenet: add MDIO routines")
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      afe3f907
    • P
      Input: synaptics - add min/max quirk for Lenovo S540 · 7f2ca8b5
      Peter Hutterer 提交于
      https://bugzilla.redhat.com/show_bug.cgi?id=1223051#c2
      
      Cc: stable@vger.kernel.org
      Tested-by: tommy.gagnes@gmail.com
      Signed-off-by: NPeter Hutterer <peter.hutterer@who-t.net>
      Signed-off-by: NDmitry Torokhov <dmitry.torokhov@gmail.com>
      7f2ca8b5
  7. 08 6月, 2015 4 次提交
  8. 07 6月, 2015 1 次提交
  9. 06 6月, 2015 2 次提交
    • C
      iscsi_ibft: filter null v4-mapped v6 addresses · e6050b61
      Chris Leech 提交于
      I've had reports of UEFI platforms failing iSCSI boot in various
      configurations, that ended up being caused by network initialization
      scripts getting tripped up by unexpected null addresses (0.0.0.0) being
      reported for gateways, dhcp servers, and dns servers.
      
      The tianocore EDK2 iSCSI driver generates an iBFT table that always uses
      IPv4-mapped IPv6 addresses for the NIC structure fields.  This results
      in values that are "not present or not specified" being reported as
      ::ffff:0.0.0.0 rather than all zeros as specified.
      
      The iscsi_ibft module filters unspecified fields from the iBFT from
      sysfs, preventing userspace from using invalid values and making it easy
      to check for the presence of a value.  This currently fails in regard to
      these mapped null addresses.
      
      In order to remain consistent with how the iBFT information is exposed,
      we should accommodate the behavior of the tianocore iSCSI driver as it's
      already in the wild in a large number of servers.
      
      Tested under qemu using an OVMF build of tianocore EDK2.
      Signed-off-by: NChris Leech <cleech@redhat.com>
      Reviewed-by: NMike Christie <michaelc@cs.wisc.edu>
      Signed-off-by: NKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
      e6050b61
    • R
      drm: fix writing to /sys/class/drm/*/status · 38d8571d
      Russell King 提交于
      Writing to a file is supposed to return the number of bytes written.
      Returning zero unfortunately causes bash to constantly spin trying
      to write to the sysfs file, to such an extent that even ^c and ^z
      have no effect.  The only way out of that is to kill the shell and
      log back in.  This isn't nice behaviour.
      
      Fix it by returning the number of characters written to sysfs files.
      
      [airlied: used suggestion from Al Viro]
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      38d8571d
  10. 05 6月, 2015 7 次提交
  11. 04 6月, 2015 2 次提交