Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pinctrl: starfive: switch to regmap for gpio registers #36

Closed
wants to merge 51 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
e2fa858
lib/string: optimized memcpy
teknoraver Jul 16, 2021
1e67750
lib/string: optimized memmove
teknoraver Jul 16, 2021
d871ce7
lib/string: optimized memset
teknoraver Jul 16, 2021
462c59b
riscv: use the generic string routines
teknoraver Jun 25, 2021
61e6bff
dt-bindings: riscv: add starfive jh7100 bindings
pdp7 Jul 13, 2021
06d307e
[WIP] dt-bindings: clock: starfive: Add JH7100 Clock Definitions
geertu Jun 25, 2021
d1bcd95
[WIP] dt-bindings: reset: starfive: Add JH7100 Reset Definitions
geertu Jun 25, 2021
33a40a7
[WIP] dt-bindings: clock: starfive: Add preliminary JH7100 bindings
geertu Jun 1, 2021
5d1d3cb
[NOT-FOR-UPSTREAM] clk: Make clk_ignore_unused public
geertu Jun 25, 2021
2f5cedf
[WIP] clk: starfive: Add preliminary JH7100 Clock Generator Driver
geertu Jun 1, 2021
99f152c
dt-bindings: hwmon: add starfive,jh7100-temp bindings
esmil Jun 6, 2021
95b1758
hwmon: (sfctemp) Add StarFive JH7100 temperature sensor
esmil Jun 6, 2021
67e5bf2
dt-bindings: mfd: convert tps65086.txt to YAML
esmil Jun 24, 2021
9a1aa37
mfd: tps65086: Make interrupt line optional
esmil May 3, 2021
4f9e649
power: reset: Add TPS65086 restart driver
esmil May 3, 2021
86c9f61
mfd: tps65086: Add cell entry for reset driver
esmil May 3, 2021
1d54444
[WIP] dt-bindings: dma: dw-axi-dmac: Increase DMA channel limit to 16
geertu May 27, 2021
78044ba
drivers/hw_random: Add StarFive JH7100 Random Number Generator driver
huanfeng-sf Jan 7, 2021
c149109
sifive/sifive_l2_cache: Add sifive_l2_flush64_range function
Jan 7, 2021
c408e0d
sifive/sifive_l2_cache: Add Starfive support
Feb 15, 2021
f44938c
sifive/sifive_l2_cache: Add disabling IRQ option (workaround)
Feb 13, 2021
7d20097
sifive/sifive_l2_cache: Print a backtrace on out-of-range flushes
geertu May 21, 2021
6bc5d8f
sifive/sifive_l2_cache: Align the address to cache line
atishp04 Jun 12, 2021
87b7873
riscv/starfive: Add VIC7100 support
Jan 7, 2021
064c718
drivers/pwm: Add SiFive PWM PTC driver
Jan 7, 2021
4ab3b62
drivers/pwm/pwm-sifive-ptc: Clear PWM CNTR
Mar 15, 2021
7ccc2f8
drivers/dma: Add dw-axi-dmac-starfive driver for VIC7100
Jan 7, 2021
8d7d53b
drivers/dma: Fix VIC7100 dw-axi-dmac-platform driver addition
mike-scott May 1, 2021
8ca3386
drivers/dma: dw-axi-dmac-starfive: Remove calls specific to ARM64 ACPI
geertu Jun 29, 2021
7388970
net: stmmac: Configure gtxclk based on speed
Apr 6, 2021
c58104b
net: stmmac: use GFP_DMA32
teknoraver May 21, 2021
4fcf532
drivers/video/fbdev and drivers/media/platform: starfive drivers added
jackzhustf Jan 10, 2021
6c8346f
media: starfive: Remove MODULE_SUPPORTED_DEVICE macro call
Jul 5, 2021
f56264c
video: fbdev: starfive: update fb driver
jackzhustf Mar 5, 2021
3e8574b
video: fbdev: starfive: workaround for unavailable pointer of dtb
jackzhustf Mar 16, 2021
c4b2ffc
video: fbdev: starfive: fix compiler warnings
esmil May 6, 2021
7d9c57e
video: fbdev: starfive: improve error handling
esmil May 6, 2021
5f38ded
video: fbdev: starfive: fix modpost build error (missing license)
sarnold May 13, 2021
beb37aa
video: fbdev: starfive: fix fb bug about HDMI display
May 15, 2021
afe6ead
video: fbdev: starfive: FB_STARFIVE_HDMI_TDA998X depends on DRM_FBDEV…
geertu May 18, 2021
e8dcca6
video: fbdev: starfive: Fix frame buffer reserved memory resource con…
geertu May 18, 2021
e4d48d5
video: fbdev: starfive: Use round_up() instead of _ALIGN_UP()
geertu Jun 22, 2021
558eb47
nvdla: add NVDLA driver
farzadfch Sep 21, 2018
e42e0e9
spi: cadence-quadspi: Allow compilation on RISC-V
esmil Apr 27, 2021
560028a
RISC-V: Support non-coherent DMA operations
atishp04 Jun 12, 2021
409d70e
riscv: dts: Add JH7100 and BeagleV Starlight support
Jan 22, 2021
3a51455
[NOT-FOR-UPSTREAM] riscv: Add starfive jh7100 starlight fedora defconfig
Jul 2, 2021
4cc2778
[NOT-FOR-UPSTREAM] Add build instructions
esmil May 5, 2021
9c1b177
[WIP] pinctrl: starfive: Add pinctrl driver for JH7100 SoC
esmil Jul 6, 2021
fd75ad5
[WIP] pinctrl: starfive: Reset pinmux settings
esmil Jul 17, 2021
434a004
pinctrl: starfive: switch to regmap for gpio registers
pdp7 Jul 25, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/clock/starfive,jh7100-clkgen.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: StarFive JH7100 Clock Generator

maintainers:
- FIXME <[email protected]>
- Geert Uytterhoeven <[email protected]>

properties:
compatible:
const: starfive,jh7100-clkgen

reg:
maxItems: 1

clocks:
items:
- description: Main clock source (default 25 MHz)
- description: Application-specific clock source (12-27 MHz)

clock-names:
items:
- const: osc_sys
- const: osc_aud

'#clock-cells':
const: 1
description:
See <dt-bindings/clock/starfive-jh7100.h> for valid indices.

required:
- compatible
- reg
- clocks
- clock-names
- '#clock-cells'

additionalProperties: false

examples:
- |
clkgen: clock-controller@11800000 {
compatible = "starfive,jh7100-clkgen";
reg = <0x11800000 0x10000>;
clocks = <&osc_sys>, <&osc_aud>;
clock-names = "osc_sys", "osc_aud";
#clock-cells = <1>;
};
6 changes: 3 additions & 3 deletions Documentation/devicetree/bindings/dma/snps,dw-axi-dmac.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ properties:

dma-channels:
minimum: 1
maximum: 8
maximum: 16

snps,dma-masters:
description: |
Expand All @@ -71,14 +71,14 @@ properties:
Channel priority specifier associated with the DMA channels.
$ref: /schemas/types.yaml#/definitions/uint32-array
minItems: 1
maxItems: 8
maxItems: 16

snps,block-size:
description: |
Channel block size specifier associated with the DMA channels.
$ref: /schemas/types.yaml#/definitions/uint32-array
minItems: 1
maxItems: 8
maxItems: 16

snps,axi-max-burst-len:
description: |
Expand Down
43 changes: 43 additions & 0 deletions Documentation/devicetree/bindings/hwmon/starfive,jh7100-temp.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/hwmon/starfive,jh7100-temp.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: StarFive JH7100 Temperature Sensor

maintainers:
- Emil Renner Berthing <[email protected]>

description: |
StarFive Technology Co. JH7100 embedded temperature sensor

properties:
compatible:
enum:
- starfive,jh7100-temp

reg:
maxItems: 1

'#thermal-sensor-cells':
const: 0

interrupts:
maxItems: 1

required:
- compatible
- reg
- interrupts

additionalProperties: false

examples:
- |
tmon: tmon@124a0000 {
compatible = "starfive,jh7100-temp";
reg = <0x124a0000 0x10000>;
#thermal-sensor-cells = <0>;
interrupts = <122>;
};
124 changes: 124 additions & 0 deletions Documentation/devicetree/bindings/mfd/ti,tps65086.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/mfd/ti,tps65086.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: TPS65086 Power Management Integrated Circuit (PMIC)

maintainers:
- Emil Renner Berthing <[email protected]>

properties:
compatible:
const: ti,tps65086

reg:
const: 0x5e
description: I2C slave address

interrupts:
maxItems: 1

interrupt-controller: true

'#interrupt-cells':
const: 2
description: |
The first cell is the IRQ number. The second cell is the flags,
encoded as trigger masks from ../interrupt-controller/interrupts.txt.

gpio-controller: true

'#gpio-cells':
const: 2
description: |
The first cell is the pin number and the second cell is used to specify
flags. See ../gpio/gpio.txt for more information.

regulators:
type: object
description: |
List of child nodes that specify the regulator initialization data.
Child nodes must be named after their hardware counterparts:
buck[1-6], ldoa[1-3], swa1, swb[1-2], and vtt.
Each child node is defined using the standard binding for regulators and
the optional regulator properties defined below.

patternProperties:
"^buck[1-6]$":
type: object
$ref: ../regulator/regulator.yaml

properties:
regulator-name: true
regulator-boot-on: true
regulator-always-on: true
regulator-min-microvolt: true
regulator-max-microvolt: true
ti,regulator-step-size-25mv:
type: boolean
description: |
Set this if the regulator is factory set with a 25mv step voltage
mapping.
ti,regulator-decay:
type: boolean
description: |
Set this if the output needs to decay, default is for the output
to slew down.

additionalProperties: false

"^(ldoa[1-3]|swa1|swb[1-2]|vtt)$":
type: object
$ref: ../regulator/regulator.yaml

properties:
regulator-name: true
regulator-boot-on: true
regulator-always-on: true
regulator-min-microvolt: true
regulator-max-microvolt: true

additionalProperties: false

additionalProperties: false

required:
- compatible
- reg
- gpio-controller
- '#gpio-cells'
- regulators

examples:
- |
#include <dt-bindings/interrupt-controller/irq.h>
i2c0 {
#address-cells = <1>;
#size-cells = <0>;

pmic: pmic@5e {
compatible = "ti,tps65086";
reg = <0x5e>;
interrupt-parent = <&gpio1>;
interrupts = <28 IRQ_TYPE_LEVEL_LOW>;
interrupt-controller;
#interrupt-cells = <2>;
gpio-controller;
#gpio-cells = <2>;

regulators {
buck1 {
regulator-name = "vcc1";
regulator-min-microvolt = <1600000>;
regulator-max-microvolt = <1600000>;
regulator-boot-on;
ti,regulator-decay;
ti,regulator-step-size-25mv;
};
};
};
};

...
54 changes: 0 additions & 54 deletions Documentation/devicetree/bindings/mfd/tps65086.txt

This file was deleted.

27 changes: 27 additions & 0 deletions Documentation/devicetree/bindings/riscv/starfive.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/riscv/starfive.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: StarFive SoC-based boards

maintainers:
- Michael Zhu <[email protected]>
- Drew Fustini <[email protected]>

description:
StarFive SoC-based boards

properties:
$nodename:
const: '/'
compatible:
oneOf:
- items:
- const: beagle,beaglev-starlight-jh7100-r0
- const: starfive,jh7100

additionalProperties: true

...
1 change: 1 addition & 0 deletions Documentation/hwmon/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ Hardware Monitoring Kernel Drivers
sch5627
sch5636
scpi-hwmon
sfctemp
sht15
sht21
sht3x
Expand Down
32 changes: 32 additions & 0 deletions Documentation/hwmon/sfctemp.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
.. SPDX-License-Identifier: GPL-2.0

Kernel driver sfctemp
=====================

Supported chips:
- StarFive JH7100

Authors:
- Emil Renner Berthing <[email protected]>

Description
-----------

This driver adds support for reading the built-in temperature sensor on the
JH7100 RISC-V SoC by StarFive Technology Co. Ltd.

``sysfs`` interface
-------------------

The temperature sensor can be enabled, disabled and queried via the standard
hwmon interface in sysfs under ``/sys/class/hwmon/hwmonX`` for some value of
``X``:

================ ==== =============================================
Name Perm Description
================ ==== =============================================
temp1_enable RW Enable or disable temperature sensor.
Automatically enabled by the driver,
but may be disabled to save power.
temp1_input RO Temperature reading in milli-degrees Celsius.
================ ==== =============================================
8 changes: 8 additions & 0 deletions MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -16751,6 +16751,14 @@ L: [email protected]
S: Supported
F: drivers/net/ethernet/sfc/

SFCTEMP HWMON DRIVER
M: Emil Renner Berthing <[email protected]>
L: [email protected]
S: Maintained
F: Documentation/devicetree/bindings/hwmon/starfive,jh7100-temp.yaml
F: Documentation/hwmon/sfctemp.rst
F: drivers/hwmon/sfctemp.c

SFF/SFP/SFP+ MODULE SUPPORT
M: Russell King <[email protected]>
L: [email protected]
Expand Down
Loading