Skip to content

VER-721: ath12k: select default board file based on machine compatible#70

Closed
adrian-nicolau wants to merge 2 commits intotg-v6.18-ath12k-nextfrom
VER-61-TG-APP-is-running-on-Digital-Board
Closed

VER-721: ath12k: select default board file based on machine compatible#70
adrian-nicolau wants to merge 2 commits intotg-v6.18-ath12k-nextfrom
VER-61-TG-APP-is-running-on-Digital-Board

Conversation

@adrian-nicolau
Copy link

Currently ath12k is loaded on two platforms: "siklu,n366" (using 8devices noni card) and "siklu,ipq6018-ctu" (using vvdn card). Load specific board firmware based on DT compatible string and fallback to default one if neither.


bd_api = 1;
ret = ath12k_core_fetch_board_data_api_1(ab, bd, ATH12K_DEFAULT_BOARD_FILE);

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it would be a better idea to use the same method as we did for the TG brd file:
make board.bin a symbolic link, and then link it to the correct file in boot time, and then load the driver.
This will allow us more flexibility (e.g. we might have 10s of board files in the future) and also is more flexible since we don't do change in the kernel.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The filesystem is read-only, I cannot create a link after boot, need to do it from Yocto and there's no differentiation for machines there.

Copy link
Collaborator

@shmuelhazan shmuelhazan Feb 3, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in the TG project,
/lib/firmware/wil6210.brd is a symlink to /run/selected_board_file.brd (or something similar).
When the system boots, we create /run/selected_board_file.brd as a symlink to /lib/firmware/xyz.brd (based on the machine's JSON file).
When the driver starts, it loads /lib/firmware/wil6210.brd which redirects to -> /run/selected_board_file.brd -> /lib/firmware/xyz.brd.
/run/ is a temporary file system and is RW.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh understood, two levels of symlinks, closing this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants