1. 13 8月, 2021 8 次提交
  2. 12 8月, 2021 1 次提交
  3. 10 8月, 2021 6 次提交
  4. 06 8月, 2021 1 次提交
    • B
      loop: Select I/O scheduler 'none' from inside add_disk() · 2112f5c1
      Bart Van Assche 提交于
      We noticed that the user interface of Android devices becomes very slow
      under memory pressure. This is because Android uses the zram driver on top
      of the loop driver for swapping, because under memory pressure the swap
      code alternates reads and writes quickly, because mq-deadline is the
      default scheduler for loop devices and because mq-deadline delays writes by
      five seconds for such a workload with default settings. Fix this by making
      the kernel select I/O scheduler 'none' from inside add_disk() for loop
      devices. This default can be overridden at any time from user space,
      e.g. via a udev rule. This approach has an advantage compared to changing
      the I/O scheduler from userspace from 'mq-deadline' into 'none', namely
      that synchronize_rcu() does not get called.
      
      This patch changes the default I/O scheduler for loop devices from
      'mq-deadline' into 'none'.
      
      Additionally, this patch reduces the Android boot time on my test setup
      with 0.5 seconds compared to configuring the loop I/O scheduler from user
      space.
      
      Cc: Christoph Hellwig <hch@lst.de>
      Cc: Ming Lei <ming.lei@redhat.com>
      Cc: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
      Cc: Martijn Coenen <maco@android.com>
      Cc: Jaegeuk Kim <jaegeuk@kernel.org>
      Signed-off-by: NBart Van Assche <bvanassche@acm.org>
      Link: https://lore.kernel.org/r/20210805174200.3250718-3-bvanassche@acm.orgSigned-off-by: NJens Axboe <axboe@kernel.dk>
      2112f5c1
  5. 03 8月, 2021 5 次提交
  6. 30 7月, 2021 7 次提交
  7. 29 7月, 2021 3 次提交
    • M
      HID: ft260: fix device removal due to USB disconnect · db8d3a21
      Michael Zaidman 提交于
      This commit fixes a functional regression introduced by the commit 82f09a63
      ("HID: ft260: improve error handling of ft260_hid_feature_report_get()")
      when upon USB disconnect, the FTDI FT260 i2c device is still available within
      the /dev folder.
      
      In my company's product, where the host USB to FT260 USB connection is
      hard-wired in the PCB, the issue is not reproducible. To reproduce it, I used
      the VirtualBox Ubuntu 20.04 VM and the UMFT260EV1A development module for the
      FTDI FT260 chip:
      
      Plug the UMFT260EV1A module into a USB port and attach it to VM.
      
      The VM shows 2 i2c devices under the /dev:
          michael@michael-VirtualBox:~$ ls /dev/i2c-*
          /dev/i2c-0  /dev/i2c-1
      
      The i2c-0 is not related to the FTDI FT260:
          michael@michael-VirtualBox:~$ cat /sys/bus/i2c/devices/i2c-0/name
          SMBus PIIX4 adapter at 4100
      
      The i2c-1 is created by hid-ft260.ko:
          michael@michael-VirtualBox:~$ cat /sys/bus/i2c/devices/i2c-1/name
          FT260 usb-i2c bridge on hidraw1
      
      Now, detach the FTDI FT260 USB device from VM. We expect the /dev/i2c-1
      to disappear, but it's still here:
          michael@michael-VirtualBox:~$ ls /dev/i2c-*
          /dev/i2c-0  /dev/i2c-1
      
      And the kernel log shows:
          [  +0.001202] usb 2-2: USB disconnect, device number 3
          [  +0.000109] ft260 0003:0403:6030.0002: failed to retrieve system status
          [  +0.000316] ft260 0003:0403:6030.0003: failed to retrieve system status
      
      It happens because the commit 82f09a63 changed the ft260_get_system_config()
      return logic. This caused the ft260_is_interface_enabled() to exit with error
      upon the FT260 device USB disconnect, which in turn, aborted the ft260_remove()
      before deleting the FT260 i2c device and cleaning its sysfs stuff.
      
      This commit restores the FT260 USB removal functionality and improves the
      ft260_is_interface_enabled() code to handle correctly all chip modes defined
      by the device interface configuration pins DCNF0 and DCNF1.
      Signed-off-by: NMichael Zaidman <michael.zaidman@gmail.com>
      Acked-by: NAaron Jones (FTDI-UK) <aaron.jones@ftdichip.com>
      Signed-off-by: NJiri Kosina <jkosina@suse.cz>
      db8d3a21
    • S
      ACPI: DPTF: Fix reading of attributes · 41a8457f
      Srinivas Pandruvada 提交于
      The current assumption that methods to read PCH FIVR attributes will
      return integer, is not correct. There is no good way to return integer
      as negative numbers are also valid.
      
      These read methods return a package of integers. The first integer returns
      status, which is 0 on success and any other value for failure. When the
      returned status is zero, then the second integer returns the actual value.
      
      This change fixes this issue by replacing acpi_evaluate_integer() with
      acpi_evaluate_object() and use acpi_extract_package() to extract results.
      
      Fixes: 2ce6324e ("ACPI: DPTF: Add PCH FIVR participant driver")
      Signed-off-by: NSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
      Cc: 5.10+ <stable@vger.kernel.org> # 5.10+
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      41a8457f
    • H
      Revert "ACPI: resources: Add checks for ACPI IRQ override" · e0eef369
      Hui Wang 提交于
      The commit 0ec4e55e ("ACPI: resources: Add checks for ACPI IRQ
      override") introduces regression on some platforms, at least it makes
      the UART can't get correct irq setting on two different platforms,
      and it makes the kernel can't bootup on these two platforms.
      
      This reverts commit 0ec4e55e.
      
      Regression-discuss: https://bugzilla.kernel.org/show_bug.cgi?id=213031Reported-by: NPGNd <pgnet.dev@gmail.com>
      Cc: 5.4+ <stable@vger.kernel.org> # 5.4+
      Signed-off-by: NHui Wang <hui.wang@canonical.com>
      Acked-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
      e0eef369
  8. 28 7月, 2021 9 次提交