1. 17 May, 2018 21 commits
  2. 16 May, 2018 1 commit
  3. 14 May, 2018 1 commit
  4. 06 May, 2018 4 commits
  5. 03 May, 2018 7 commits
  6. 19 Apr, 2018 3 commits
    • Zhang Rui's avatar
      rtc: cmos: introduce quirks to enable use_acpi_alarm mode · 36d91a4d
      Zhang Rui authored
      Use ACPI for RTC Alarm only for Intel platforms
      1. with Low Power S0 support
      2. with HPET RTC emulation enabled
      3. no earlier than 2015
      
      Note that, during the test, it is found that this patch
      1. works in 4.15-rc kernel
      2. hangs the platform after suspend-to-idle for 2 or 3 times, in 4.15.0
      3. works again in 4.16-rc3 kernel.
      4. works in the latest 4.15.12 stable kernel.
      
      Thus although this patch breaks 4.15.0 kernel for some unknown reason,
      still, it is safe for both upstream and backport.
      Signed-off-by: default avatarZhang Rui <rui.zhang@intel.com>
      Signed-off-by: default avatarAlexandre Belloni <alexandre.belloni@bootlin.com>
      36d91a4d
    • Zhang Rui's avatar
      rtc: cmos: acknowledge ACPI driven wake alarms upon resume · c6d3a278
      Zhang Rui authored
      Previously, the RTC alarm is acknowledged either by the cmos rtc irq
      handler, or by the hpet rtc irq handler.
      
      When using ACPI RTC Fixed event as the RTC alarm, the RTC alarm is
      acknowledged by the ACPI RTC event handler, as addressed in the previous
      patch.
      But, when resume from suspend-to-ram (ACPI S3), the ACPI SCI is cleared
      right after resume, thus the ACPI RTC event handler is not invoked at all,
      results in the RTC Alarm unacknowledged.
      
      Handle this by comparing the current time and the RTC Alarm time in the
      rtc_cmos driver .resume() callback
      1. Assume the wakeup event has already been fired if the RTC Alarm time
         is earlier than/equal to the current time, and ACK the RTC Alarm.
      2. Assume the wakeup event has not been fired if the RTC Alarm time
         is later than current time, and re-arm it if needed.
      Signed-off-by: default avatarZhang Rui <rui.zhang@intel.com>
      Signed-off-by: default avatarAlexandre Belloni <alexandre.belloni@bootlin.com>
      c6d3a278
    • Zhang Rui's avatar
      rtc: cmos: allow using ACPI for RTC alarm instead of HPET · 311ee9c1
      Zhang Rui authored
      It's found that the HPET timer prevents the platform from entering
      Low Power S0 on some new Intel platforms.
      
      This means that
      1. users can still use RTC wake Alarm for suspend-to-idle, but the system
         never enters Low Power S0, which is a waste of power.
      or
      2. if users want to put the system into Low Power S0, they can not use
         RTC as the wakeup source.
      
      To fix this, we need to stop using the HPET timer for wake alarm.
      But disabling CONFIG_HPET_EMULATE_RTC is not an option because HPET
      emulates PIT at the same time, and this is needed on some of these
      platforms.
      
      Thus, introduce a new mode (use_acpi_alarm) to the rtc_cmos driver,
      so that, even with CONFIG_HPET_EMULATE_RTC enabled, it's still possible to
      use ACPI SCI for RTC Alarm, including UIE/AIE/wkalrm, instead of HPET.
      
      Only necessary changes are made for the new "use_acpi_alarm" mode, including
      1. drop all the calls to HPET emulation code, including the HPET irq
         handler for rtc interrupt.
      2. enabling/disabling ACPI RTC Fixed event upon RTC UIE/AIE request.
      3. acknowledge the RTC Alarm in ACPI RTC Fixed event handler.
      
      There is no functional change made in this patch if the new mode is not
      enabled.
      
      Note: this "use_acpi_alarm" mode is made based on the assumption that
      ACPI RTC Fixed event is reliable both at runtime and during system wakeup.
      And this has been verified on a couple of platforms I have, including
      a MS Surface Pro 4 (SKL), a Lenovo Yoga 900 (SKL), and a HP 9360 (KBL).
      Signed-off-by: default avatarZhang Rui <rui.zhang@intel.com>
      Signed-off-by: default avatarAlexandre Belloni <alexandre.belloni@bootlin.com>
      311ee9c1
  7. 16 Apr, 2018 3 commits
    • Linus Torvalds's avatar
      Linux 4.17-rc1 · 60cc43fc
      Linus Torvalds authored
      60cc43fc
    • Linus Torvalds's avatar
      Merge tag 'for-4.17-part2-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux · e37563bb
      Linus Torvalds authored
      Pull more btrfs updates from David Sterba:
       "We have queued a few more fixes (error handling, log replay,
        softlockup) and the rest is SPDX updates that touche almost all files
        so the diffstat is long"
      
      * tag 'for-4.17-part2-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux:
        btrfs: Only check first key for committed tree blocks
        btrfs: add SPDX header to Kconfig
        btrfs: replace GPL boilerplate by SPDX -- sources
        btrfs: replace GPL boilerplate by SPDX -- headers
        Btrfs: fix loss of prealloc extents past i_size after fsync log replay
        Btrfs: clean up resources during umount after trans is aborted
        btrfs: Fix possible softlock on single core machines
        Btrfs: bail out on error during replay_dir_deletes
        Btrfs: fix NULL pointer dereference in log_dir_items
      e37563bb
    • Linus Torvalds's avatar
      Merge tag '4.17-rc1SMB3-Fixes' of git://git.samba.org/sfrench/cifs-2.6 · 09c9b0ea
      Linus Torvalds authored
      Pull cifs fixes from Steve French:
       "SMB3 fixes, a few for stable, and some important cleanup work from
        Ronnie of the smb3 transport code"
      
      * tag '4.17-rc1SMB3-Fixes' of git://git.samba.org/sfrench/cifs-2.6:
        cifs: change validate_buf to validate_iov
        cifs: remove rfc1002 hardcoded constants from cifs_discard_remaining_data()
        cifs: Change SMB2_open to return an iov for the error parameter
        cifs: add resp_buf_size to the mid_q_entry structure
        smb3.11: replace a 4 with server->vals->header_preamble_size
        cifs: replace a 4 with server->vals->header_preamble_size
        cifs: add pdu_size to the TCP_Server_Info structure
        SMB311: Improve checking of negotiate security contexts
        SMB3: Fix length checking of SMB3.11 negotiate request
        CIFS: add ONCE flag for cifs_dbg type
        cifs: Use ULL suffix for 64-bit constant
        SMB3: Log at least once if tree connect fails during reconnect
        cifs: smb2pdu: Fix potential NULL pointer dereference
      09c9b0ea