nuvoton,npcx-pinctrl
Vendor: Nuvoton Technology Corporation
Description
The Nuvoton pin controller is a singleton node responsible for controlling
pin function selection and pin properties. For example, you can use these
nodes to select peripheral pin functions.
Here is a list of supported standard pin properties:
- bias-pull-down: Enable pull-down resistor.
- bias-pull-up: Enable pull-up resistor.
- drive-open-drain: Output driver is open-drain.
Custom pin properties for npcx series are available also:
- pinmux-locked: Lock pinmux configuration for peripheral device
- pinmux-gpio: Inverse pinmux back to gpio
- psl-in-mode: Select the assertion detection mode of PSL input
- psl-in-pol: Select the assertion detection polarity of PSL input
An example for NPCX7 family, include the chip level pinctrl DTSI file in the
board level DTS:
#include <nuvoton/npcx/npcx7/npcx7-pinctrl.dtsi>
We want to use the I2C0_0 port of the NPCX7M6FB controller and enable the
internal 3.3V pull-up if its i2c frequency won't exceed 400kHz.
To change a pin's pinctrl default properties, add a reference to the
pin in the board's DTS file and set the properties as below:
&i2c0_0_sda_scl_gpb4_b5 {
bias-pull-up; /* Enable internal pull-up for i2c0_0 */
pinmux-locked; /* Lock pinmuxing */
};
&i2c0_0 {
pinctrl-0 = <&i2c0_0_sda_scl_gpb4_b5>;
pinctrl-names = "default";
}
Properties
Top level properties
These property descriptions apply to “nuvoton,npcx-pinctrl” nodes themselves. This page also describes child node properties in the following sections.
Node specific properties
Properties not inherited from the base binding file.
(None)
Deprecated node specific properties
Deprecated properties not inherited from the base binding file.
(None)
Base properties
Properties inherited from the base binding file, which defines common properties that may be set on many nodes. Not all of these may apply to the “nuvoton,npcx-pinctrl” compatible.
Name |
Type |
Details |
---|---|---|
|
|
indicates the operational status of a device
Legal values: See Important properties for more information. |
|
|
compatible strings
This property is required. See Important properties for more information. |
|
|
register space
See Important properties for more information. |
|
|
name of each register space
|
|
|
interrupts for device
See Important properties for more information. |
|
|
extended interrupt specifier for device
|
|
|
name of each interrupt
|
|
|
phandle to interrupt controller node
|
|
|
Human readable string describing the device (used as device_get_binding() argument)
See Important properties for more information. This property is deprecated. |
|
|
Clock gate information
|
|
|
name of each clock
|
|
|
number of address cells in reg property
|
|
|
number of size cells in reg property
|
|
|
DMA channels specifiers
|
|
|
Provided names of DMA channel specifiers
|
|
|
IO channels specifiers
|
|
|
Provided names of IO channel specifiers
|
|
|
mailbox / IPM channels specifiers
|
|
|
Provided names of mailbox / IPM channel specifiers
|
|
|
Power domain specifiers
|
|
|
Provided names of power domain specifiers
|
|
|
Number of cells in power-domains property
|
|
|
Do not initialize device automatically on boot. Device should be manually
initialized using device_init().
|
|
|
Property to identify that a device can be used as wake up source.
When this property is provided a specific flag is set into the
device that tells the system that the device is capable of
wake up the system.
Wake up capable devices are disabled (interruptions will not wake up
the system) by default but they can be enabled at runtime if necessary.
|
|
|
Automatically configure the device for runtime power management after the
init function runs.
|
|
|
List of power states that will disable this device power.
|
Child node properties
Name |
Type |
Details |
---|---|---|
|
|
Configurations of pinmux selection
|
|
|
Configurations of device control such as tri-state, io type and so on.
|
|
|
A map to PUPD_ENn register/bit that enable pull-up/down of NPCX peripheral devices.
Please don't overwrite this property in the board-level DT driver.
|
|
|
Offset to PSL_CTS register that is used for PSL input's status and detection mode.
Please don't overwrite this property in the board-level DT driver.
|
|
|
A map to DEVALTn that configures detection polarity of PSL input pads.
Please don't overwrite this property in the board-level DT driver.
|
|
|
Lock pinmux selection
|
|
|
Inverse pinmux selection to GPIO
|
|
|
The assertion detection mode of PSL input selection
- "level": Select the detection mode to level detection
- "edge": Select the detection mode to edge detection
Legal values: |
|
|
The assertion detection polarity of PSL input selection
- "low-falling": Select the detection polarity to low/falling
- "high-rising": Select the detection polarity to high/rising
Legal values: |
|
|
enable pull-up resistor
|
|
|
enable pull-down resistor
|
|
|
drive with open drain (hardware AND)
|