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

crypto: ccp: Fix compile error on file csv-dev.h #353

Merged
merged 1 commit into from
Aug 6, 2024
Merged

Conversation

opsiff
Copy link
Member

@opsiff opsiff commented Aug 6, 2024

hygon inclusion
category: bugfix
CVE: NA


The error messages is shown as following:

In file included from drivers/crypto/ccp/hygon/csv-dev.c:19: drivers/crypto/ccp/hygon/csv-dev.h:18:36: error: ‘struct sev_user_data_status’ declared inside parameter list will not be visible outside of this definition or declaration [-Werror]
18 | void csv_update_api_version(struct sev_user_data_status *status);
| ^~~~~~~~~~~~~~~~~~~~
drivers/crypto/ccp/hygon/csv-dev.c:34:6: error: conflicting types for ‘csv_update_api_version’; have ‘void(struct sev_user_data_status *)’
34 | void csv_update_api_version(struct sev_user_data_status *status)
| ^~~~~~~~~~~~~~~~~~~~~~
drivers/crypto/ccp/hygon/csv-dev.h:18:6: note: previous declaration of ‘csv_update_api_version’ with type ‘void(struct sev_user_data_status *)’
18 | void csv_update_api_version(struct sev_user_data_status *status);
| ^~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors

hygon inclusion
category: bugfix
CVE: NA

---------------------------

The error messages is shown as following:

In file included from drivers/crypto/ccp/hygon/csv-dev.c:19:
drivers/crypto/ccp/hygon/csv-dev.h:18:36: error: ‘struct sev_user_data_status’ declared inside parameter list will not be visible outside of this definition or declaration [-Werror]
   18 | void csv_update_api_version(struct sev_user_data_status *status);
      |                                    ^~~~~~~~~~~~~~~~~~~~
drivers/crypto/ccp/hygon/csv-dev.c:34:6: error: conflicting types for ‘csv_update_api_version’; have ‘void(struct sev_user_data_status *)’
   34 | void csv_update_api_version(struct sev_user_data_status *status)
      |      ^~~~~~~~~~~~~~~~~~~~~~
drivers/crypto/ccp/hygon/csv-dev.h:18:6: note: previous declaration of ‘csv_update_api_version’ with type ‘void(struct sev_user_data_status *)’
   18 | void csv_update_api_version(struct sev_user_data_status *status);
      |      ^~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors

Signed-off-by: hanliyang <hanliyang@hygon.cn>
@opsiff opsiff merged commit 1e1ca42 into linux-6.6.y Aug 6, 2024
6 of 10 checks passed
@opsiff opsiff deleted the ccp-patches branch August 6, 2024 10:04
@deepin-ci-robot
Copy link

deepin pr auto review

关键摘要:

  • 在新增的 #include <linux/psp-sev.h> 中,需要确认是否有使用到该头文件中的函数或数据结构。如果没有使用,则应该移除该包含,以避免不必要的依赖。
  • hygon_csv_buildcsv_fops 变量的定义是否在文件的其他地方?如果这些变量在其他地方没有定义,那么这个头文件可能不是必需的,或者应该包含它们的定义。

是否建议立即修改:

  • 是,应该立即检查 #include <linux/psp-sev.h> 是否真的必要,并确保 hygon_csv_buildcsv_fops 在文件中正确定义。

@deepin-ci-robot deepin-ci-robot requested review from BLumia and myml August 6, 2024 10:04
@deepin-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign zeno-sole for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

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