Skip to content

Commit c50af4a

Browse files
committed
soc: wch: Deduplicate common files across ch32v socs
Moves shared files from multiple ch32v SoCs into a new `common/` directory to eliminate duplication. Signed-off-by: Miguel Gazquez <miguel.gazquez@bootlin.com>
1 parent 0f1d7d3 commit c50af4a

File tree

14 files changed

+12
-154
lines changed

14 files changed

+12
-154
lines changed

soc/wch/ch32v/ch32v00x/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
# SPDX-License-Identifier: Apache-2.0
44

55
zephyr_sources(
6-
soc_irq.S
7-
vector.S
6+
../common/qingke_v2x/soc_irq.S
7+
../common/qingke_v2x/vector.S
88
)
99

1010
zephyr_include_directories(.)

soc/wch/ch32v/ch32v00x/soc_irq.S

Lines changed: 0 additions & 20 deletions
This file was deleted.

soc/wch/ch32v/qingke_v4c/pinctrl_soc.h renamed to soc/wch/ch32v/common/qingke_v4/pinctrl_soc.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
/**
1111
* @brief Type to hold a pin's pinctrl configuration.
1212
*/
13-
struct ch32v208_pinctrl_soc_pin {
13+
struct qingke_v4_pinctrl_soc_pin {
1414
uint32_t config: 22;
1515
bool bias_pull_up: 1;
1616
bool bias_pull_down: 1;
@@ -21,7 +21,7 @@ struct ch32v208_pinctrl_soc_pin {
2121
uint8_t slew_rate: 2;
2222
};
2323

24-
typedef struct ch32v208_pinctrl_soc_pin pinctrl_soc_pin_t;
24+
typedef struct qingke_v4_pinctrl_soc_pin pinctrl_soc_pin_t;
2525

2626
#define Z_PINCTRL_STATE_PIN_INIT(node_id, prop, idx) \
2727
{ \

soc/wch/ch32v/qingke_v2a/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
# SPDX-License-Identifier: Apache-2.0
44

55
zephyr_sources(
6-
soc_irq.S
7-
vector.S
6+
../common/qingke_v2x/soc_irq.S
7+
../common/qingke_v2x/vector.S
88
)
99

1010
zephyr_include_directories(.)

soc/wch/ch32v/qingke_v2a/vector.S

Lines changed: 0 additions & 29 deletions
This file was deleted.

soc/wch/ch32v/qingke_v4b/CMakeLists.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
# SPDX-License-Identifier: Apache-2.0
44

55
zephyr_sources(
6-
soc_irq.S
7-
vector.S
6+
../common/qingke_v4/soc_irq.S
7+
../common/qingke_v4/vector.S
88
)
99

10-
zephyr_include_directories(.)
10+
zephyr_include_directories(../common/qingke_v4)

0 commit comments

Comments
 (0)