diff mbox series

[11/13] scsi: pm8001: Fix kernel-doc warnings

Message ID 20211124005217.2300458-12-bvanassche@acm.org (mailing list archive)
State Superseded
Headers show
Series A series of small SCSI patches | expand

Commit Message

Bart Van Assche Nov. 24, 2021, 12:52 a.m. UTC
Fix the following kernel-doc warnings:

drivers/scsi/pm8001/pm8001_ctl.c:900: warning: cannot understand function prototype: 'const char *const mpiStateText[] = '
drivers/scsi/pm8001/pm8001_ctl.c:930: warning: Function parameter or member 'attr' not described in 'ctl_hmi_error_show'
drivers/scsi/pm8001/pm8001_ctl.c:951: warning: Function parameter or member 'attr' not described in 'ctl_raae_count_show'
drivers/scsi/pm8001/pm8001_ctl.c:972: warning: Function parameter or member 'attr' not described in 'ctl_iop0_count_show'
drivers/scsi/pm8001/pm8001_ctl.c:993: warning: Function parameter or member 'attr' not described in 'ctl_iop1_count_show'

Fixes: 4ddbea1b6f51 ("scsi: pm80xx: Add sysfs attribute to check MPI state")
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
---
 drivers/scsi/pm8001/pm8001_ctl.c | 24 ++++++++++++------------
 1 file changed, 12 insertions(+), 12 deletions(-)

Comments

Jinpu Wang Nov. 24, 2021, 6:08 a.m. UTC | #1
On Wed, Nov 24, 2021 at 1:52 AM Bart Van Assche <bvanassche@acm.org> wrote:
>
> Fix the following kernel-doc warnings:
>
> drivers/scsi/pm8001/pm8001_ctl.c:900: warning: cannot understand function prototype: 'const char *const mpiStateText[] = '
> drivers/scsi/pm8001/pm8001_ctl.c:930: warning: Function parameter or member 'attr' not described in 'ctl_hmi_error_show'
> drivers/scsi/pm8001/pm8001_ctl.c:951: warning: Function parameter or member 'attr' not described in 'ctl_raae_count_show'
> drivers/scsi/pm8001/pm8001_ctl.c:972: warning: Function parameter or member 'attr' not described in 'ctl_iop0_count_show'
> drivers/scsi/pm8001/pm8001_ctl.c:993: warning: Function parameter or member 'attr' not described in 'ctl_iop1_count_show'
>
> Fixes: 4ddbea1b6f51 ("scsi: pm80xx: Add sysfs attribute to check MPI state")
> Signed-off-by: Bart Van Assche <bvanassche@acm.org>
looks good to me, thx!
Acked-by: Jack Wang <jinpu.wang@ionos.com>
> ---
>  drivers/scsi/pm8001/pm8001_ctl.c | 24 ++++++++++++------------
>  1 file changed, 12 insertions(+), 12 deletions(-)
>
> diff --git a/drivers/scsi/pm8001/pm8001_ctl.c b/drivers/scsi/pm8001/pm8001_ctl.c
> index 397eb9f6a1dd..41a63c9b719b 100644
> --- a/drivers/scsi/pm8001/pm8001_ctl.c
> +++ b/drivers/scsi/pm8001/pm8001_ctl.c
> @@ -889,14 +889,6 @@ static ssize_t pm8001_show_update_fw(struct device *cdev,
>  static DEVICE_ATTR(update_fw, S_IRUGO|S_IWUSR|S_IWGRP,
>         pm8001_show_update_fw, pm8001_store_update_fw);
>
> -/**
> - * ctl_mpi_state_show - controller MPI state check
> - * @cdev: pointer to embedded class device
> - * @buf: the buffer returned
> - *
> - * A sysfs 'read-only' shost attribute.
> - */
> -
>  static const char *const mpiStateText[] = {
>         "MPI is not initialized",
>         "MPI is successfully initialized",
> @@ -904,6 +896,14 @@ static const char *const mpiStateText[] = {
>         "MPI initialization failed with error in [31:16]"
>  };
>
> +/**
> + * ctl_mpi_state_show - controller MPI state check
> + * @cdev: pointer to embedded class device
> + * @attr: device attribute (unused)
> + * @buf: the buffer returned
> + *
> + * A sysfs 'read-only' shost attribute.
> + */
>  static ssize_t ctl_mpi_state_show(struct device *cdev,
>                 struct device_attribute *attr, char *buf)
>  {
> @@ -920,11 +920,11 @@ static DEVICE_ATTR_RO(ctl_mpi_state);
>  /**
>   * ctl_hmi_error_show - controller MPI initialization fails
>   * @cdev: pointer to embedded class device
> + * @attr: device attribute (unused)
>   * @buf: the buffer returned
>   *
>   * A sysfs 'read-only' shost attribute.
>   */
> -
>  static ssize_t ctl_hmi_error_show(struct device *cdev,
>                 struct device_attribute *attr, char *buf)
>  {
> @@ -941,11 +941,11 @@ static DEVICE_ATTR_RO(ctl_hmi_error);
>  /**
>   * ctl_raae_count_show - controller raae count check
>   * @cdev: pointer to embedded class device
> + * @attr: device attribute (unused)
>   * @buf: the buffer returned
>   *
>   * A sysfs 'read-only' shost attribute.
>   */
> -
>  static ssize_t ctl_raae_count_show(struct device *cdev,
>                 struct device_attribute *attr, char *buf)
>  {
> @@ -962,11 +962,11 @@ static DEVICE_ATTR_RO(ctl_raae_count);
>  /**
>   * ctl_iop0_count_show - controller iop0 count check
>   * @cdev: pointer to embedded class device
> + * @attr: device attribute (unused)
>   * @buf: the buffer returned
>   *
>   * A sysfs 'read-only' shost attribute.
>   */
> -
>  static ssize_t ctl_iop0_count_show(struct device *cdev,
>                 struct device_attribute *attr, char *buf)
>  {
> @@ -983,11 +983,11 @@ static DEVICE_ATTR_RO(ctl_iop0_count);
>  /**
>   * ctl_iop1_count_show - controller iop1 count check
>   * @cdev: pointer to embedded class device
> + * @attr: device attribute (unused)
>   * @buf: the buffer returned
>   *
>   * A sysfs 'read-only' shost attribute.
>   */
> -
>  static ssize_t ctl_iop1_count_show(struct device *cdev,
>                 struct device_attribute *attr, char *buf)
>  {
diff mbox series

Patch

diff --git a/drivers/scsi/pm8001/pm8001_ctl.c b/drivers/scsi/pm8001/pm8001_ctl.c
index 397eb9f6a1dd..41a63c9b719b 100644
--- a/drivers/scsi/pm8001/pm8001_ctl.c
+++ b/drivers/scsi/pm8001/pm8001_ctl.c
@@ -889,14 +889,6 @@  static ssize_t pm8001_show_update_fw(struct device *cdev,
 static DEVICE_ATTR(update_fw, S_IRUGO|S_IWUSR|S_IWGRP,
 	pm8001_show_update_fw, pm8001_store_update_fw);
 
-/**
- * ctl_mpi_state_show - controller MPI state check
- * @cdev: pointer to embedded class device
- * @buf: the buffer returned
- *
- * A sysfs 'read-only' shost attribute.
- */
-
 static const char *const mpiStateText[] = {
 	"MPI is not initialized",
 	"MPI is successfully initialized",
@@ -904,6 +896,14 @@  static const char *const mpiStateText[] = {
 	"MPI initialization failed with error in [31:16]"
 };
 
+/**
+ * ctl_mpi_state_show - controller MPI state check
+ * @cdev: pointer to embedded class device
+ * @attr: device attribute (unused)
+ * @buf: the buffer returned
+ *
+ * A sysfs 'read-only' shost attribute.
+ */
 static ssize_t ctl_mpi_state_show(struct device *cdev,
 		struct device_attribute *attr, char *buf)
 {
@@ -920,11 +920,11 @@  static DEVICE_ATTR_RO(ctl_mpi_state);
 /**
  * ctl_hmi_error_show - controller MPI initialization fails
  * @cdev: pointer to embedded class device
+ * @attr: device attribute (unused)
  * @buf: the buffer returned
  *
  * A sysfs 'read-only' shost attribute.
  */
-
 static ssize_t ctl_hmi_error_show(struct device *cdev,
 		struct device_attribute *attr, char *buf)
 {
@@ -941,11 +941,11 @@  static DEVICE_ATTR_RO(ctl_hmi_error);
 /**
  * ctl_raae_count_show - controller raae count check
  * @cdev: pointer to embedded class device
+ * @attr: device attribute (unused)
  * @buf: the buffer returned
  *
  * A sysfs 'read-only' shost attribute.
  */
-
 static ssize_t ctl_raae_count_show(struct device *cdev,
 		struct device_attribute *attr, char *buf)
 {
@@ -962,11 +962,11 @@  static DEVICE_ATTR_RO(ctl_raae_count);
 /**
  * ctl_iop0_count_show - controller iop0 count check
  * @cdev: pointer to embedded class device
+ * @attr: device attribute (unused)
  * @buf: the buffer returned
  *
  * A sysfs 'read-only' shost attribute.
  */
-
 static ssize_t ctl_iop0_count_show(struct device *cdev,
 		struct device_attribute *attr, char *buf)
 {
@@ -983,11 +983,11 @@  static DEVICE_ATTR_RO(ctl_iop0_count);
 /**
  * ctl_iop1_count_show - controller iop1 count check
  * @cdev: pointer to embedded class device
+ * @attr: device attribute (unused)
  * @buf: the buffer returned
  *
  * A sysfs 'read-only' shost attribute.
  */
-
 static ssize_t ctl_iop1_count_show(struct device *cdev,
 		struct device_attribute *attr, char *buf)
 {