Skip to content
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

Add Kernel Version Check #1117

Closed
wants to merge 5 commits into from
Closed

Conversation

HTRamsey
Copy link
Contributor

Adds a check for minimum supported kernel version

@HTRamsey HTRamsey requested a review from a team as a code owner March 14, 2024 16:18
Copy link
Member

@AniruddhaKanhere AniruddhaKanhere left a comment

Choose a reason for hiding this comment

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

The changes look good to me.

Thank you @HTRamsey for taking the time to contribute!

Thanks

@@ -148,6 +148,10 @@

/*---------------------------------------------------------------------------*/

#if ( ( tskKERNEL_VERSION_MAJOR < 8 ) || ( ( tskKERNEL_VERSION_MAJOR == 8 ) && ( tskKERNEL_VERSION_MINOR < 1 ) ) )
Copy link
Member

Choose a reason for hiding this comment

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

I suppose that this specific version is used due to the fact that before this pdMS_TO_TICKS did not exist which is used a lot in this library.

Copy link
Contributor Author

@HTRamsey HTRamsey Mar 14, 2024

Choose a reason for hiding this comment

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

It's actually from this but looking at the changelog myself I think maybe it should be v8.2 cause that's when task notifications were added. I can try and at least see the oldest version that will compile later.

Copy link
Member

Choose a reason for hiding this comment

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

Thank you! That would be great.

Copy link
Member

Choose a reason for hiding this comment

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

@HTRamsey

Task notifications are used by the IP stack only if ipconfigSELECT_USES_NOTIFY is enabled. Network interfaces might still use it, depending on how the EMAC task is implemented.

@AniruddhaKanhere
Copy link
Member

@ActoryOu should we be including the kernel headers here

target_compile_options(freertos_plus_tcp_build_test_${header}
before compile options as the build check is failing there.

@HTRamsey HTRamsey mentioned this pull request Mar 20, 2024
@ActoryOu
Copy link
Member

@ActoryOu should we be including the kernel headers here

target_compile_options(freertos_plus_tcp_build_test_${header}

before compile options as the build check is failing there.

Sorry for late response.
Yeah, that helps. And @HTRamsey created a better solution by #1120.
Let's do it that way.

@tony-josi-aws
Copy link
Member

@HTRamsey

Thanks for this PR. But to me, it seems like the kernel version check is not adding much value here, as without the check as well, the compilation should fail if the user is not using the right kernel version.

Another reason is that, though event groups are added with kernel version v8.1, task notifications (which were added with v8.2) could be used in the network interface or with ipconfigSELECT_USES_NOTIFY. For users who do not use task notification, it doesnt make much sense to have minimum version as v8.2

@HTRamsey
Copy link
Contributor Author

@tony-josi-aws to your first point, the value would be in making it obvious to users why it is not compiling, instead of getting more questions on the forum. To the second point, the check is currently for v8.1, not v8.2.

@HTRamsey HTRamsey closed this Mar 29, 2024
@HTRamsey HTRamsey deleted the dev-kernel-version branch March 29, 2024 10:30
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.

4 participants