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

Fix 'MAXPHYS' macro redefinition warning in macOS #706

Merged
5 commits merged into from
Feb 13, 2024
Merged

Conversation

ghost
Copy link

@ghost ghost commented Feb 7, 2024

No description provided.

@ghost ghost requested a review from rdmark February 7, 2024 11:03
@ghost ghost self-assigned this Feb 7, 2024
@ghost ghost linked an issue Feb 7, 2024 that may be closed by this pull request
@rdmark
Copy link
Member

rdmark commented Feb 7, 2024

@dgsga any chance we can check for capabilities and not platform? What does this macro do in the first place anyways, and is it still needed?

@ghost
Copy link
Author

ghost commented Feb 7, 2024

@dgsga any chance we can check for capabilities and not platform?
Done.
What does this macro do in the first place anyways, and is it still needed?
Not sure on either count!

@rdmark
Copy link
Member

rdmark commented Feb 7, 2024

According to ChatGPT:

In C, MAXPHYS is a macro that defines the maximum size of a single I/O transfer in bytes. It is often used in operating system kernel development to set limits on the size of data transfers. The value of MAXPHYS can vary depending on the operating system and hardware architecture. It's typically set to a value that optimizes performance and system stability.

@ghost
Copy link
Author

ghost commented Feb 9, 2024

According to ChatGPT:

In C, MAXPHYS is a macro that defines the maximum size of a single I/O transfer in bytes. It is often used in operating system kernel development to set limits on the size of data transfers. The value of MAXPHYS can vary depending on the operating system and hardware architecture. It's typically set to a value that optimizes performance and system stability.

If this is the case it makes sense to check for platform...

@rdmark
Copy link
Member

rdmark commented Feb 9, 2024

Fair point.

Copy link

sonarcloud bot commented Feb 12, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@ghost ghost merged commit 4e3a87a into main Feb 13, 2024
2 of 11 checks passed
@ghost ghost deleted the 705-dgsga-maxphys branch February 13, 2024 08:16
This pull request was closed.
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.

'MAXPHYS' macro in ad_cp.c gives a macro redefined warning in macOS
1 participant