1. 22 11月, 2019 1 次提交
  2. 02 10月, 2019 1 次提交
  3. 07 9月, 2019 6 次提交
  4. 19 7月, 2019 1 次提交
  5. 03 7月, 2019 1 次提交
    • M
      clocksource/drivers: Make Hyper-V clocksource ISA agnostic · fd1fea68
      Michael Kelley 提交于
      Hyper-V clock/timer code and data structures are currently mixed
      in with other code in the ISA independent drivers/hv directory as
      well as the ISA dependent Hyper-V code under arch/x86.
      
      Consolidate this code and data structures into a Hyper-V clocksource driver
      to better follow the Linux model. In doing so, separate out the ISA
      dependent portions so the new clocksource driver works for x86 and for the
      in-process Hyper-V on ARM64 code.
      
      To start, move the existing clockevents code to create the new clocksource
      driver. Update the VMbus driver to call initialization and cleanup routines
      since the Hyper-V synthetic timers are not independently enumerated in
      ACPI.
      
      No behavior is changed and no new functionality is added.
      Suggested-by: NMarc Zyngier <marc.zyngier@arm.com>
      Signed-off-by: NMichael Kelley <mikelley@microsoft.com>
      Signed-off-by: NThomas Gleixner <tglx@linutronix.de>
      Reviewed-by: NVitaly Kuznetsov <vkuznets@redhat.com>
      Cc: "bp@alien8.de" <bp@alien8.de>
      Cc: "will.deacon@arm.com" <will.deacon@arm.com>
      Cc: "catalin.marinas@arm.com" <catalin.marinas@arm.com>
      Cc: "mark.rutland@arm.com" <mark.rutland@arm.com>
      Cc: "linux-arm-kernel@lists.infradead.org" <linux-arm-kernel@lists.infradead.org>
      Cc: "gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>
      Cc: "linux-hyperv@vger.kernel.org" <linux-hyperv@vger.kernel.org>
      Cc: "olaf@aepfle.de" <olaf@aepfle.de>
      Cc: "apw@canonical.com" <apw@canonical.com>
      Cc: "jasowang@redhat.com" <jasowang@redhat.com>
      Cc: "marcelo.cerri@canonical.com" <marcelo.cerri@canonical.com>
      Cc: Sunil Muthuswamy <sunilmut@microsoft.com>
      Cc: KY Srinivasan <kys@microsoft.com>
      Cc: "sashal@kernel.org" <sashal@kernel.org>
      Cc: "vincenzo.frascino@arm.com" <vincenzo.frascino@arm.com>
      Cc: "linux-arch@vger.kernel.org" <linux-arch@vger.kernel.org>
      Cc: "linux-mips@vger.kernel.org" <linux-mips@vger.kernel.org>
      Cc: "linux-kselftest@vger.kernel.org" <linux-kselftest@vger.kernel.org>
      Cc: "arnd@arndb.de" <arnd@arndb.de>
      Cc: "linux@armlinux.org.uk" <linux@armlinux.org.uk>
      Cc: "ralf@linux-mips.org" <ralf@linux-mips.org>
      Cc: "paul.burton@mips.com" <paul.burton@mips.com>
      Cc: "daniel.lezcano@linaro.org" <daniel.lezcano@linaro.org>
      Cc: "salyzyn@android.com" <salyzyn@android.com>
      Cc: "pcc@google.com" <pcc@google.com>
      Cc: "shuah@kernel.org" <shuah@kernel.org>
      Cc: "0x7f454c46@gmail.com" <0x7f454c46@gmail.com>
      Cc: "linux@rasmusvillemoes.dk" <linux@rasmusvillemoes.dk>
      Cc: "huw@codeweavers.com" <huw@codeweavers.com>
      Cc: "sfr@canb.auug.org.au" <sfr@canb.auug.org.au>
      Cc: "pbonzini@redhat.com" <pbonzini@redhat.com>
      Cc: "rkrcmar@redhat.com" <rkrcmar@redhat.com>
      Cc: "kvm@vger.kernel.org" <kvm@vger.kernel.org>
      Link: https://lkml.kernel.org/r/1561955054-1838-2-git-send-email-mikelley@microsoft.com
      fd1fea68
  6. 24 6月, 2019 1 次提交
  7. 05 6月, 2019 1 次提交
  8. 11 4月, 2019 2 次提交
    • K
      Drivers: hv: vmbus: Fix race condition with new ring_buffer_info mutex · 14948e39
      Kimberly Brown 提交于
      Fix a race condition that can result in a ring buffer pointer being set
      to null while a "_show" function is reading the ring buffer's data. This
      problem was discussed here: https://lkml.org/lkml/2018/10/18/779
      
      To fix the race condition, add a new mutex lock to the
      "hv_ring_buffer_info" struct. Add a new function,
      "hv_ringbuffer_pre_init()", where a channel's inbound and outbound
      ring_buffer_info mutex locks are initialized.
      
      Acquire/release the locks in the "hv_ringbuffer_cleanup()" function,
      which is where the ring buffer pointers are set to null.
      
      Acquire/release the locks in the four channel-level "_show" functions
      that access ring buffer data. Remove the "const" qualifier from the
      "vmbus_channel" parameter and the "rbi" variable of the channel-level
      "_show" functions so that the locks can be acquired/released in these
      functions.
      
      Acquire/release the locks in hv_ringbuffer_get_debuginfo(). Remove the
      "const" qualifier from the "hv_ring_buffer_info" parameter so that the
      locks can be acquired/released in this function.
      Signed-off-by: NKimberly Brown <kimbrownkd@gmail.com>
      Reviewed-by: NMichael Kelley <mikelley@microsoft.com>
      Signed-off-by: NSasha Levin <sashal@kernel.org>
      14948e39
    • K
      Drivers: hv: vmbus: Refactor chan->state if statement · fcedbb29
      Kimberly Brown 提交于
      The chan->state "if statement" was introduced in commit 6712cc9c
      ("vmbus: don't return values for uninitalized channels"). That commit
      states that the purpose of the chan->state "if statement" is to prevent
      returning garbage or causing a kernel OOPS when the channel ring buffer
      is not initialized. The changes in this patch provide the same
      protection.
      
      Refactor the chan->state “if statement” in vmbus_chan_attr_show():
       - Instead of checking the channel state in the "if statement", check
         whether the channel ring buffer pointer is NULL. Checking the
         ring buffer pointer makes this code consistent with
         hv_ringbuffer_get_debuginfo().
      
       - Move the "if statement" to the four "_show" functions that access a
         channel ring buffer. Only four of the channel-level "_show" functions
         access a ring buffer. The ring buffer pointer does not need to be
         checked before calling the other "_show" functions, and moving the
         ring buffer pointer "if statement" to the "_show" functions that
         access a ring buffer makes the purpose of the "if statement" clear.
      Signed-off-by: NKimberly Brown <kimbrownkd@gmail.com>
      Reviewed-by: NMichael Kelley <mikelley@microsoft.com>
      Signed-off-by: NSasha Levin <sashal@kernel.org>
      fcedbb29
  9. 21 3月, 2019 1 次提交
    • K
      Drivers: hv: vmbus: Expose monitor data only when monitor pages are used · 46fc1548
      Kimberly Brown 提交于
      There are two methods for signaling the host: the monitor page mechanism
      and hypercalls. The monitor page mechanism is used by performance
      critical channels (storage, networking, etc.) because it provides
      improved throughput. However, latency is increased. Monitor pages are
      allocated to these channels.
      
      Monitor pages are not allocated to channels that do not use the monitor
      page mechanism. Therefore, these channels do not have a valid monitor id
      or valid monitor page data. In these cases, some of the "_show"
      functions return incorrect data. They return an invalid monitor id and
      data that is beyond the bounds of the hv_monitor_page array fields.
      
      The "channel->offermsg.monitor_allocated" value can be used to determine
      whether monitor pages have been allocated to a channel.
      
      Add "is_visible()" callback functions for the device-level and
      channel-level attribute groups. These functions will hide the monitor
      sysfs files when the monitor mechanism is not used.
      
      Remove ".default_attributes" from "vmbus_chan_attrs" and create a
      channel-level attribute group. These changes allow the new
      "is_visible()" callback function to be applied to the channel-level
      attributes.
      
      Call "sysfs_create_group()" in "vmbus_add_channel_kobj()" to create the
      channel's sysfs files. Add a new function,
      “vmbus_remove_channel_attr_group()”, and call it in "free_channel()" to
      remove the channel's sysfs files when the channel is closed.
      Signed-off-by: NKimberly Brown <kimbrownkd@gmail.com>
      Reviewed-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      Reviewed-by: NMichael Kelley <mikelley@microsoft.com>
      Signed-off-by: NSasha Levin <sashal@kernel.org>
      46fc1548
  10. 23 2月, 2019 1 次提交
  11. 15 2月, 2019 2 次提交
    • K
      Drivers: hv: vmbus: Expose counters for interrupts and full conditions · 396ae57e
      Kimberly Brown 提交于
      Counter values for per-channel interrupts and ring buffer full
      conditions are useful for investigating performance.
      
      Expose counters in sysfs for 2 types of guest to host interrupts:
      1) Interrupts caused by the channel's outbound ring buffer transitioning
      from empty to not empty
      2) Interrupts caused by the channel's inbound ring buffer transitioning
      from full to not full while a packet is waiting for enough buffer space to
      become available
      
      Expose 2 counters in sysfs for the number of times that write operations
      encountered a full outbound ring buffer:
      1) The total number of write operations that encountered a full
      condition
      2) The number of write operations that were the first to encounter a
      full condition
      
      Increment the outbound full condition counters in the
      hv_ringbuffer_write() function because, for most drivers, a full
      outbound ring buffer is detected in that function. Also increment the
      outbound full condition counters in the set_channel_pending_send_size()
      function. In the hv_sock driver, a full outbound ring buffer is detected
      and set_channel_pending_send_size() is called before
      hv_ringbuffer_write() is called.
      
      I tested this patch by confirming that the sysfs files were created and
      observing the counter values. The values seemed to increase by a
      reasonable amount when the Hyper-v related drivers were in use.
      Signed-off-by: NKimberly Brown <kimbrownkd@gmail.com>
      Reviewed-by: NMichael Kelley <mikelley@microsoft.com>
      Signed-off-by: NSasha Levin <sashal@kernel.org>
      396ae57e
    • A
      vmbus: Switch to use new generic UUID API · 593db803
      Andy Shevchenko 提交于
      There are new types and helpers that are supposed to be used in new code.
      
      As a preparation to get rid of legacy types and API functions do
      the conversion here.
      
      Cc: "K. Y. Srinivasan" <kys@microsoft.com>
      Cc: Haiyang Zhang <haiyangz@microsoft.com>
      Cc: Stephen Hemminger <sthemmin@microsoft.com>
      Cc: devel@linuxdriverproject.org
      Signed-off-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com>
      Reviewed-by: NMichael Kelley <mikelley@microsoft.com>
      Reviewed-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NSasha Levin <sashal@kernel.org>
      593db803
  12. 10 1月, 2019 1 次提交
  13. 14 12月, 2018 1 次提交
  14. 26 9月, 2018 1 次提交
  15. 12 9月, 2018 2 次提交
  16. 29 7月, 2018 4 次提交
  17. 08 7月, 2018 1 次提交
  18. 29 3月, 2018 1 次提交
  19. 10 1月, 2018 3 次提交
  20. 18 12月, 2017 1 次提交
  21. 10 11月, 2017 1 次提交
  22. 04 11月, 2017 2 次提交
  23. 31 10月, 2017 2 次提交
  24. 04 10月, 2017 2 次提交