-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
drivers: dm8806: link speed change interrupt handling
On the interrupt handling, one thread per driver instance is involved into monitoring the semaphor, sends inside the gpio callback triggered by the gpio interrupt. Each time, when the link parameters are change, the DM8806 is generating the gpio interrupt. After getting semaphor, the application callback function which was linked during initialization process is called to get the new link parameters with standard API calls Signed-off-by: Robert Slawinski <robert.slawinski1@gmail.com>
- Loading branch information
Showing
4 changed files
with
345 additions
and
28 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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,49 @@ | ||
# Copyright 2024 Robert Slawinski <robert.slawinski1@gmail.com> | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
# Davicom PHY DM8806 driver configuration options | ||
|
||
menuconfig PHY_DM8806 | ||
bool "Davicom PHY DM8806 driver" | ||
default y | ||
depends on DT_HAS_DAVICOM_DM8806_PHY_ENABLED | ||
depends on MDIO | ||
help | ||
Enable driver for Davicom DM8806 PHY. | ||
|
||
if PHY_DM8806 | ||
|
||
choice PHY_DM8806_TRIGGER_MODE | ||
prompt "Trigger mode" | ||
default PHY_DM8806_TRIGGER_GLOBAL_THREAD | ||
help | ||
Specify the type of triggering to be used by the driver. | ||
|
||
config PHY_DM8806_TRIGGER_NONE | ||
bool "No trigger" | ||
|
||
config PHY_DM8806_TRIGGER_GLOBAL_THREAD | ||
bool "Use global thread" | ||
depends on GPIO | ||
select PHY_DM8806_TRIGGER | ||
|
||
endchoice | ||
|
||
config PHY_DM8806_TRIGGER | ||
bool | ||
|
||
config PHY_DM8806_THREAD_PRIORITY | ||
int "Thread priority" | ||
depends on PHY_DM8806_TRIGGER_GLOBAL_THREAD | ||
default 13 | ||
help | ||
Priority of thread used by the driver to handle interrupts. | ||
|
||
config PHY_DM8806_THREAD_STACK_SIZE | ||
int "Thread stack size" | ||
depends on PHY_DM8806_TRIGGER_GLOBAL_THREAD | ||
default 1024 | ||
help | ||
Stack size of thread used by the driver to handle interrupts. | ||
|
||
endif # PHY_DM8806_TRIGGER |
Oops, something went wrong.