-
Notifications
You must be signed in to change notification settings - Fork 50
feat: add spi1 to rock2 #374
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
Open
nascs
wants to merge
12
commits into
radxa-pkg:main
Choose a base branch
from
nascs:rock2_spi1_cs-gpio
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 1 commit
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
956b38a
feat: add spi1 to rock2
nascs 812b0d1
Apply suggestions from code review
nascs 01a912b
fix: fix the file name
nascs e56e737
fix: delete num-cs property
nascs bdd0106
feat: add enc28j60 common file
nascs b1cf9c3
feat: port enc28j60 to rk3528
nascs 5bdb9b3
feat: add mcp2515 common file
nascs a3dfe7e
feat: port mcp2515 to rk3528
nascs fe6d841
fix: fix enc28j60 of rk3528
nascs 5b993c2
feat: add w5500 common file
nascs d03187b
feat: port w5500 to rk3528
nascs 1f5c26e
fix: fix spi compilation error
nascs File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
arch/arm64/boot/dts/rockchip/overlays/rk3528-spi1-cs-gpio.dts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,31 @@ | ||
| /dts-v1/; | ||
| /plugin/; | ||
| #include <dt-bindings/gpio/gpio.h> | ||
| #include <dt-bindings/pinctrl/rockchip.h> | ||
|
|
||
| / { | ||
| metadata { | ||
| title = "Enable spidev on SPI1 over PIN_26"; | ||
nascs marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| compatible = "radxa,rock-2a", "radxa,rock-2f", "radxa,medge-rk3528a-io"; | ||
| category = "misc"; | ||
| exclusive = "GPIO1_B6", "GPIO1_B7", "GPIO1_C0", "GPIO4_C1"; | ||
| description = "Enable spidev on SPI1 over PIN_26."; | ||
nascs marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| }; | ||
| }; | ||
|
|
||
| &spi1 { | ||
| status = "okay"; | ||
| #address-cells = <1>; | ||
| #size-cells = <0>; | ||
| max-freq = <50000000>; | ||
| num-cs = <1>; | ||
RadxaYuntian marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| cs-gpios = <&gpio4 RK_PC1 GPIO_ACTIVE_LOW>; | ||
| pinctrl-0 = <&spi1_pins>; | ||
nascs marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| spidev@0 { | ||
| compatible = "rockchip,spidev"; | ||
| status = "okay"; | ||
| reg = <0>; | ||
| spi-max-frequency = <50000000>; | ||
| }; | ||
| }; | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.