Commit graph

50651 commits

Author SHA1 Message Date
Maximilian Luz
167f77f7d0 power: supply: Add battery driver for Surface Aggregator Module
On newer Microsoft Surface models (specifically 7th-generation, i.e.
Surface Pro 7, Surface Book 3, Surface Laptop 3, and Surface Laptop Go),
battery and AC status/information is no longer handled via standard ACPI
devices, but instead directly via the Surface System Aggregator Module
(SSAM), i.e. the embedded controller on those devices.

While on previous generation models, battery status is also handled via
SSAM, an ACPI shim was present to translate the standard ACPI battery
interface to SSAM requests. The SSAM interface itself, which is modeled
closely after the ACPI interface, has not changed.

This commit introduces a new SSAM client device driver to support
battery status/information via the aforementioned interface on said
Surface models. It is in parts based on the standard ACPI battery
driver.

Signed-off-by: Maximilian Luz <luzmaximilian@gmail.com>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
2021-04-08 14:30:28 +02:00
Marek Czerski
52473b0740 power: reset: ltc2952: make trigger delay configurable
Make trigger delay configurable through device tree with
trigger-delay-ms property.

Trigger delay is the time to wait before starting shutdown
sequence after trigger line assertion.
Trigger delay must take into account the OFFT time configured
with the capacitor connected to OFFT pin of the LTC2952 chip.
Basically, the higher the capacitance connected to OFFT pin,
the larger trigger delay must be.

Signed-off-by: Marek Czerski <ma.czerski@gmail.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
2021-04-05 12:05:51 +02:00
Mauro Carvalho Chehab
e4e4092938 dt-bindings: power: update battery.yaml reference
Changesets: 70c23e62d2 ("dt-bindings: power: supply: Fix remaining battery.txt links")
and: 471dec8023 ("dt-bindings: power: Convert battery.txt to battery.yaml")
renamed: Documentation/devicetree/bindings/power/supply/battery.txt
to: Documentation/devicetree/bindings/power/supply/battery.yaml.

Update its cross-reference accordingly.

Fixes: 70c23e62d2 ("dt-bindings: power: supply: Fix remaining battery.txt links")
Fixes: 471dec8023 ("dt-bindings: power: Convert battery.txt to battery.yaml")
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
2021-04-02 13:00:55 +02:00
Sebastian Reichel
f735e8366a dt-bindings: power: supply: Drop power_supply.txt
The file has been replaced by power-supply.yaml and all links
have been updated to the new file.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:24 +01:00
Sebastian Reichel
70c23e62d2 dt-bindings: power: supply: Fix remaining battery.txt links
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:24 +01:00
Sebastian Reichel
3ef11821de dt-bindings: power: supply: sbs-battery: Fix dtbs_check
Existing in-tree users make use of '"ti,bq20z45", "sbs,sbs-battery"', so
add it to the list of known compatible strings.

Also add missing support for the generic 'power-supplies' property by
importing power-supply.yaml and setting unevaluatedProperties instead
of additionalProperties.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:24 +01:00
Sebastian Reichel
eb91749773 dt-bindings: power: supply: ab8500: Convert to DT schema format
Convert the binding to DT schema format.

Note: The battery node does not have a compatible value and needs
to be described from the binding file for the PMIC. That has not
yet been converted, so I kept the information in plaintext for now.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:24 +01:00
Sebastian Reichel
ee66274196 dt-bindings: power: supply: olpc-battery: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:24 +01:00
Sebastian Reichel
95b00152cb dt-bindings: power: supply: rt9455: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:24 +01:00
Sebastian Reichel
d913a03bc1 dt-bindings: power: supply: ltc294x: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
97f03280e0 dt-bindings: power: supply: lt3651: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
c44242f0d0 dt-bindings: power: supply: lp8727: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
59604ba756 dt-bindings: power: supply: da9150: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
a3388d750c dt-bindings: power: supply: axp20x: Convert to DT schema format
Convert the binding to DT schema format.

Cc: Chen-Yu Tsai <wens@csie.org>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
ee123ad978 dt-bindings: power: supply: act8945a: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
6c463222a2 dt-bindings: power: supply: pm8941-coincell: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
1a4d86b4c9 dt-bindings: power: supply: pm8941-charger: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
f444be1245 dt-bindings: power: supply: ucs1002: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
402a3cb34e dt-bindings: power: supply: max8903: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
eb3b616ee1 dt-bindings: power: supply: max17042: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
aad19ec18e dt-bindings: power: supply: max14656: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
ab1a76df6d dt-bindings: power: supply: max17040: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:55:23 +01:00
Sebastian Reichel
3004e581d9 dt-bindings: power: supply: lego-ev3-battery: Convert to DT schema format
Convert the binding to DT schema format.

Cc: David Lechner <david@lechnology.com>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: David Lechner <david@lechnology.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:59 +01:00
Sebastian Reichel
df89b2850a dt-bindings: power: supply: n900-battery: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Rejected-by: Pali Rohár <pali@kernel.org>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:54 +01:00
Sebastian Reichel
bb56712aba dt-bindings: power: supply: twl4030: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:54 +01:00
Sebastian Reichel
0e2d1823a6 dt-bindings: power: supply: tps65217: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:54 +01:00
Sebastian Reichel
4ac8f03056 dt-bindings: power: supply: tps65090: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:54 +01:00
Sebastian Reichel
dc721203c5 dt-bindings: power: supply: sc2731-charger: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:54 +01:00
Sebastian Reichel
89919370c5 dt-bindings: power: supply: sc27xx-fg: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:53 +01:00
Sebastian Reichel
2f06fcbdac dt-bindings: power: supply: ds2760: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:53 +01:00
Sebastian Reichel
f5bf381a10 dt-bindings: power: supply: sbs-manager: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:53 +01:00
Sebastian Reichel
90f6c44d7e dt-bindings: power: supply: sbs-charger: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:53 +01:00
Sebastian Reichel
437e6b6c8f dt-bindings: power: supply: isp1704: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:53 +01:00
Sebastian Reichel
464a748871 dt-bindings: power: supply: bq24735: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:53 +01:00
Sebastian Reichel
9c05cfaf3f dt-bindings: power: supply: bq2415x: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:53 +01:00
Sebastian Reichel
e7c2431759 dt-bindings: power: supply: bq24190: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:53 +01:00
Sebastian Reichel
102d4a0b69 dt-bindings: power: supply: bq24257: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:53 +01:00
Sebastian Reichel
648d383253 dt-bindings: power: supply: bq25890: Convert to DT schema format
Convert the binding to DT schema format.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:53 +01:00
Sebastian Reichel
ce49e42822 dt-bindings: power: supply: cpcap-charger: Convert to DT schema format
Convert the binding to DT schema format. I also added the missing bits
used by the only in-tree user and implemented in the driver.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Tony Lindgren <tony@atomide.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:50 +01:00
Sebastian Reichel
3c5be04549 dt-bindings: power: supply: cpcap-battery: Convert to DT schema format
Convert the binding to DT schema format. I also added the missing bits
used by the only in-tree user and implemented in the driver.

Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
Reviewed-by: Tony Lindgren <tony@atomide.com>
Reviewed-by: Rob Herring <robh@kernel.org>
2021-03-23 12:54:44 +01:00
LI Qingwu
83ee068199 dt-bindings: power: bq27xxx: add bq78z100
Add bindings for TI BQ78Z100. An I2C interface gas gauge.
It provides a fully integrated safety protection
and authentication for 1 to 2-series cell Li-Ion and
Li-Polymer battery packs.

Signed-off-by: LI Qingwu <Qing-wu.Li@leica-geosystems.com.cn>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.com>
2021-03-21 21:28:37 +01:00
Linus Torvalds
47454caf45 block-5.12-2021-03-05
-----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCAAuFiEEwPw5LcreJtl1+l5K99NY+ylx4KYFAmBCa2kQHGF4Ym9lQGtl
 cm5lbC5kawAKCRD301j7KXHgpo5TEADb8p//Qr/Uv8hiVqvrMKoVbiJ+ZXB+Z+6k
 ZMlcOryHWLbNOYYsA6soUygRkEFlFyUhfWJEvIYIr612s964+aD8cH9JhpPbGzkd
 rTGUWeHXcW0is03AgEsq5SmjRO3zI+I0Ln2IMlePY+W8xwIL8jI3pf+LiI/gzJcG
 sOxqgtS3zBzby3sU/9LDJfBCB4soqBcrp/6G6p2tK+gtVsud122LInl2/gGtXml4
 AT15T1JaPbdnOCFXiy+GIK+AQiITfmPBiM+m7mh2LabxJNTDtYSrwh5rjKQjVpyi
 N+AwVTeshzDbuoac6yuZSkLRPFfSPdgeefqCGNcpSjdJiJsvwQWHqf119CKYraLd
 d2nOn4YRK4dtLWlu4bZkJCUC+KWQhCfQNAeu/ok9OQ7d6eKmigiDA+YlAf9NdymL
 yknWzjjVxFwDKO/fGuOXq3kj/EW5JNgX1/esJAilVBojzavR9uu+fxVCvohEbc6I
 hJ9hXijY1R3wmbJbpFRo8msKSifgaFVVrb2bKUbxtUI6er1mJ+dkAM8MeKf6+LTq
 DLfyoD8o4F9+dJqHfRKIt+Pdgrm0nvcgxDPykAsX5vMoAwgeVIcyRK59wPOnTMWV
 NaRabO85hEdkTTdAB10UB7Ix7PTNHGtCxfvb9mNnPDYMrHr8qolRfCzQW9nULzLi
 ggVLgn2RLQ==
 =Cd/Z
 -----END PGP SIGNATURE-----

Merge tag 'block-5.12-2021-03-05' of git://git.kernel.dk/linux-block

Pull block fixes from Jens Axboe:

 - NVMe fixes:
      - more device quirks (Julian Einwag, Zoltán Böszörményi, Pascal
        Terjan)
      - fix a hwmon error return (Daniel Wagner)
      - fix the keep alive timeout initialization (Martin George)
      - ensure the model_number can't be changed on a used subsystem
        (Max Gurtovoy)

 - rsxx missing -EFAULT on copy_to_user() failure (Dan)

 - rsxx remove unused linux.h include (Tian)

 - kill unused RQF_SORTED (Jean)

 - updated outdated BFQ comments (Joseph)

 - revert work-around commit for bd_size_lock, since we removed the
   offending user in this merge window (Damien)

* tag 'block-5.12-2021-03-05' of git://git.kernel.dk/linux-block:
  nvmet: model_number must be immutable once set
  nvme-fabrics: fix kato initialization
  nvme-hwmon: Return error code when registration fails
  nvme-pci: add quirks for Lexar 256GB SSD
  nvme-pci: mark Kingston SKC2000 as not supporting the deepest power state
  nvme-pci: mark Seagate Nytro XM1440 as QUIRK_NO_NS_DESC_LIST.
  rsxx: Return -EFAULT if copy_to_user() fails
  block/bfq: update comments and default value in docs for fifo_expire
  rsxx: remove unused including <linux/version.h>
  block: Drop leftover references to RQF_SORTED
  block: revert "block: fix bd_size_lock use"
2021-03-05 12:59:37 -08:00
Linus Torvalds
6bf331d5ce Devicetree fixes for v5.12-rc:
- Another batch of graph and video-interfaces schema conversions
 
 - Drop DT header symlink for dropped C6X arch
 
 - Fix bcm2711-hdmi schema error
 -----BEGIN PGP SIGNATURE-----
 
 iQJEBAABCgAuFiEEktVUI4SxYhzZyEuo+vtdtY28YcMFAmBCT0cQHHJvYmhAa2Vy
 bmVsLm9yZwAKCRD6+121jbxhw5qnEACbN4K1EbJs4DYhZnOzBK0hzq+9t8MEHlvu
 GWyO7xJAkU8uEETkOVOk5Qk5E9ud/DUKMV0EOj6JDElnT5mydE2t4mFXAIEfe9so
 J9T/jrAjQGDBA7ZIRp3N/r4ye83LW04wBytbytFPwQmQru0EcwBjUPHsQElnts7Z
 CFGkJJ7yteXd13Qt+in+/7h0vqjhIM/On0G4uOBxpavDDZnsdyRYeE5YykkbtDRM
 aqcYOw07rNSKjtxoofc7h0J8YThn20DO4TREQ4PD2zuIFojDxaBaS0CriZ/facWv
 vjw53x/4dkmGADbBdSQG5XZnF2YuTeoVEa3SPJU9mUEG+OA5fdmUareLFZEmZCNn
 CeyLW0mOG8dtEJuHzOw1BeLbcWIcxeTLyNpPy4RDgMSr4ocHGd2ng/E2Tk/Vr8dC
 MKaEiKa17w67JzzNpQsghjAl3M7DW3kvkFk3gQA8lz3KVMxoJZIg4XyAWbdFKpUE
 3xKQ1z4fh8uOcvQKwzstyhUgA4dSac27Ehs+wmrluzEi2Z6PfoITnnO+5/ZSkTge
 MmHtzANVVUEYo3bG894I05xLFIu5T3bmqoSlkoD3oKDNo2NbQpm++KskUrAO9tFt
 e5zpvQCwMq4ihZH0QfJYK89KkKMJPOhqa62+xCNTVT3QxaYMAe5W8jxRfHZVPTee
 imRwbL0CUw==
 =cVN0
 -----END PGP SIGNATURE-----

Merge tag 'devicetree-fixes-for-5.12-1' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux

Pull devicetree fixes from Rob Herring:

 - Another batch of graph and video-interfaces schema conversions

 - Drop DT header symlink for dropped C6X arch

 - Fix bcm2711-hdmi schema error

* tag 'devicetree-fixes-for-5.12-1' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux:
  dt-bindings: media: Use graph and video-interfaces schemas, round 2
  dts: drop dangling c6x symlink
  dt-bindings: bcm2711-hdmi: Fix broken schema
2021-03-05 12:12:28 -08:00
Linus Torvalds
cee407c5cc * Doc fixes
* selftests fixes
 * Add runstate information to the new Xen support
 * Allow compiling out the Xen interface
 * 32-bit PAE without EPT bugfix
 * NULL pointer dereference bugfix
 -----BEGIN PGP SIGNATURE-----
 
 iQFIBAABCAAyFiEE8TM4V0tmI4mGbHaCv/vSX3jHroMFAmA+lGcUHHBib256aW5p
 QHJlZGhhdC5jb20ACgkQv/vSX3jHroMaMQf/Q8bQr5vVAeNk+1MyRmzNqFEbLqbe
 h50f4Wd2N+svZ6XinQH1vvuQm1WYj/g616Q3nCeYwCJyY34g5tf60XcuAMnVRIzw
 qc2IUvSAJ3faVElMrSA5thN3bkPzJpRrdIpQGBgOd+rT+eQkPSsJlTy34JJmvbmh
 xFGjoVj49tYEkFfpxEbtytW6QiYtPz/ai8SARRXbEUWO/pVzdkgK5XWshRhE9vpB
 GLCEXUngdPokJMblRMuK4YOSFQXXHobAJAgPwSzguDV41qezXaKOGYOLe7+V+0kH
 z607RnQc1wGgsLanT13okYMQr09/XCjpvFkZ9CK2bIJPsyWP+ihA/37hVQ==
 =1GNo
 -----END PGP SIGNATURE-----

Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm

Pull KVM fixes from Paolo Bonzini:

 - Doc fixes

 - selftests fixes

 - Add runstate information to the new Xen support

 - Allow compiling out the Xen interface

 - 32-bit PAE without EPT bugfix

 - NULL pointer dereference bugfix

* tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm:
  KVM: SVM: Clear the CR4 register on reset
  KVM: x86/xen: Add support for vCPU runstate information
  KVM: x86/xen: Fix return code when clearing vcpu_info and vcpu_time_info
  selftests: kvm: Mmap the entire vcpu mmap area
  KVM: Documentation: Fix index for KVM_CAP_PPC_DAWR1
  KVM: x86: allow compiling out the Xen hypercall interface
  KVM: xen: flush deferred static key before checking it
  KVM: x86/mmu: Set SPTE_AD_WRPROT_ONLY_MASK if and only if PML is enabled
  KVM: x86: hyper-v: Fix Hyper-V context null-ptr-deref
  KVM: x86: remove misplaced comment on active_mmu_pages
  KVM: Documentation: rectify rst markup in kvm_run->flags
  Documentation: kvm: fix messy conversion from .txt to .rst
2021-03-04 11:26:17 -08:00
David Woodhouse
30b5c851af KVM: x86/xen: Add support for vCPU runstate information
This is how Xen guests do steal time accounting. The hypervisor records
the amount of time spent in each of running/runnable/blocked/offline
states.

In the Xen accounting, a vCPU is still in state RUNSTATE_running while
in Xen for a hypercall or I/O trap, etc. Only if Xen explicitly schedules
does the state become RUNSTATE_blocked. In KVM this means that even when
the vCPU exits the kvm_run loop, the state remains RUNSTATE_running.

The VMM can explicitly set the vCPU to RUNSTATE_blocked by using the
KVM_XEN_VCPU_ATTR_TYPE_RUNSTATE_CURRENT attribute, and can also use
KVM_XEN_VCPU_ATTR_TYPE_RUNSTATE_ADJUST to retrospectively add a given
amount of time to the blocked state and subtract it from the running
state.

The state_entry_time corresponds to get_kvmclock_ns() at the time the
vCPU entered the current state, and the total times of all four states
should always add up to state_entry_time.

Co-developed-by: Joao Martins <joao.m.martins@oracle.com>
Signed-off-by: Joao Martins <joao.m.martins@oracle.com>
Signed-off-by: David Woodhouse <dwmw@amazon.co.uk>
Message-Id: <20210301125309.874953-2-dwmw2@infradead.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2021-03-02 14:30:54 -05:00
Kai Huang
7d2cdad0da KVM: Documentation: Fix index for KVM_CAP_PPC_DAWR1
It should be 7.23 instead of 7.22, which has already been taken by
KVM_CAP_X86_BUS_LOCK_EXIT.

Signed-off-by: Kai Huang <kai.huang@intel.com>
Message-Id: <20210226094832.380394-1-kai.huang@intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2021-03-02 14:30:53 -05:00
Joseph Qi
4168a8d27e block/bfq: update comments and default value in docs for fifo_expire
Correct the comments since bfq_fifo_expire[0] is for async request,
while bfq_fifo_expire[1] is for sync request.
Also update docs, according the source code, the default
fifo_expire_async is 250ms, and fifo_expire_sync is 125ms.

Signed-off-by: Joseph Qi <joseph.qi@linux.alibaba.com>
Acked-by: Paolo Valente <paolo.valente@linaro.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2021-03-02 11:25:38 -07:00
Rob Herring
b5a95bb188 dt-bindings: media: Use graph and video-interfaces schemas, round 2
A couple of media schemas got applied without using or incorrectly
using the video-interfaces.yaml and graph.yaml schemas. Fix them up
before we have more copy-n-paste errors.

Fixes: 41b3e23376 ("media: dt-bindings: media: Add bindings for imx334")
Fixes: d899e5f1db ("media: dt-bindings: media: imx258: add bindings for IMX258 sensor")
Fixes: 918b866edf ("media: dt-bindings: Remove old ov5647.yaml file, update ovti,ov5647.yaml")
Fixes: 22f2b47517 ("media: dt-bindings: media: i2c: Add OV8865 bindings documentation")
Fixes: 29a202fa7a ("media: dt-bindings: media: i2c: Add OV5648 bindings documentation")
Cc: Sakari Ailus <sakari.ailus@linux.intel.com>
Cc: Mauro Carvalho Chehab <mchehab@kernel.org>
Cc: Dave Stevenson <dave.stevenson@raspberrypi.com>
Cc: Jacopo Mondi <jacopo@jmondi.org>
Cc: "Paul J. Murphy" <paul.j.murphy@intel.com>
Cc: Daniele Alessandrelli <daniele.alessandrelli@intel.com>
Cc: Krzysztof Kozlowski <krzk@kernel.org>
Cc: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Cc: linux-media@vger.kernel.org
Signed-off-by: Rob Herring <robh@kernel.org>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Acked-by: Krzysztof Kozlowski <krzk@kernel.org>
Link: https://lore.kernel.org/r/20210223210127.55455-1-robh@kernel.org
2021-03-01 11:30:21 -06:00
Linus Torvalds
03dc748bf1 More new code for 5.12:
- Restore a disused sysctl control knob that was inadvertently dropped
   during the merge window to avoid fstests regressions.
 - Don't speculatively release freed blocks from the busy list until
   we're actually allocating them, which fixes a rare log recovery
   regression.
 - Don't nest transactions when scanning for free space.
 - Add an idiot^Wmaintainer light to detect nested transactions. ;)
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEUzaAxoMeQq6m2jMV+H93GTRKtOsFAmA3zW8ACgkQ+H93GTRK
 tOtT4xAAmZ5BdQ6V3yUeT/N++L6Ax62T2VzEryZvVK/ZFyVBRYKi9LOL1exq1cja
 HXINPuYWAD8TbGVU9/lZR1yUX/y1VvJR0EPly8EN6WpGFeErSxLs++YzP1Q8iv5i
 ZtniscpGE6JvCcDeRH5kBfklGpyzTf3t6Xe8x+6+/aawf34ChNlM/gQcAyKvYYU5
 Jb9j7BqbRAnhvPEfa554yxIIoZhmTDYY7Wx7VMKCMcOP1lfriC+I1iuiZIMONIQJ
 mMgz9XnHVo256+YvkvwRKp294r+MEkuJL5EBXrs01r3PwVdaigo13qTk8l1ZC3zS
 VYkC/sRoiyMwnJvKEUNtnM3/8Zu/DvPp9iqXiWc60UBGqpBkm8Jgv+W6H7u1FinP
 0M0Wt2wHC7e51uW5G/8QwUXZv+n8IZHyZkkYbjyXRkhfyFlexYwTVchZz9q/RB/A
 HEZ9jcIke8Rwkav4f0kJ00Y/7FQSPn6ItapXf92rl00z3Z5S2sqBaT5kIotsW0Ke
 634yPknkLuBDQg4j8l3A88ik2SNFRQQfBXsjt27He/s2wV0Dj8RjDnLWfoV7P5to
 Sc2lx3HhL4OCojAXXAFP3MDKz0nqcuUTPoPCeS6QKQGcjTzVvoI7ZutXODcxi67k
 Q7AK+gIqHRWA8F+4wciYDwAHMES1rRAa7/iuYmtCtT1sBdXp9NU=
 =g9K3
 -----END PGP SIGNATURE-----

Merge tag 'xfs-5.12-merge-6' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux

Pull more xfs updates from Darrick Wong:
 "The most notable fix here prevents premature reuse of freed metadata
  blocks, and adding the ability to detect accidental nested
  transactions, which are not allowed here.

   - Restore a disused sysctl control knob that was inadvertently
     dropped during the merge window to avoid fstests regressions.

   - Don't speculatively release freed blocks from the busy list until
     we're actually allocating them, which fixes a rare log recovery
     regression.

   - Don't nest transactions when scanning for free space.

   - Add an idiot^Wmaintainer light to detect nested transactions. ;)"

* tag 'xfs-5.12-merge-6' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux:
  xfs: use current->journal_info for detecting transaction recursion
  xfs: don't nest transactions when scanning for eofblocks
  xfs: don't reuse busy extents on extent trim
  xfs: restore speculative_cow_prealloc_lifetime sysctl
2021-02-28 11:45:25 -08:00
Linus Torvalds
5ceabb6078 Merge branch 'work.misc' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
Pull misc vfs updates from Al Viro:
 "Assorted stuff pile - no common topic here"

* 'work.misc' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
  whack-a-mole: don't open-code iminor/imajor
  9p: fix misuse of sscanf() in v9fs_stat2inode()
  audit_alloc_mark(): don't open-code ERR_CAST()
  fs/inode.c: make inode_init_always() initialize i_ino to 0
  vfs: don't unnecessarily clone write access for writable fds
2021-02-27 08:07:12 -08:00