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

mtd: Remove an unused-variable adev #218

Merged

Conversation

Avenger-285714
Copy link
Collaborator

There was an unused-variable 'adev' brings a warning.

Resolve following error when '-Werror' was enabled:

drivers/mtd/mtdpart.c: In function ‘mtd_part_acpi_parse’: drivers/mtd/mtdpart.c:584:29: error: unused variable ‘adev’ [-Werror=unused-variable]
584 | struct acpi_device *adev;
| ^~~~
cc1: all warnings being treated as errors

Reported-by: Mingcong Bai baimingcong@uniontech.com

There was an unused-variable 'adev' brings a warning.

Resolve following error when '-Werror' was enabled:

drivers/mtd/mtdpart.c: In function ‘mtd_part_acpi_parse’:
drivers/mtd/mtdpart.c:584:29: error: unused variable ‘adev’ [-Werror=unused-variable]
  584 |         struct acpi_device *adev;
      |                             ^~~~
cc1: all warnings being treated as errors

Reported-by: Mingcong Bai <baimingcong@uniontech.com>
Signed-off-by: WangYuli <wangyuli@uniontech.com>
@deepin-ci-robot
Copy link

deepin pr auto review

关键摘要:

  • 代码中移除了变量 adev,但未提供替代逻辑或解释为何移除。

是否建议立即修改:

  • 是,需要确认移除 adev 变量是否会影响其他代码部分的功能,并确保移除是故意的且不会引入bug。如果 adev 变量不再需要,应该同时更新所有相关的代码,并添加相应的注释说明原因。

@deepin-ci-robot deepin-ci-robot requested a review from myml May 27, 2024 06:51
@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 goldendeng 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