Skip to content

Commit

Permalink
Merge patch series "Declare local functions static"
Browse files Browse the repository at this point in the history
Bart Van Assche <bvanassche@acm.org> says:

Hi Martin,

There are several 32-bit ARM SCSI drivers that trigger compiler warnings
about missing function declarations. This patch series fixes these
compiler warnings by declaring local functions static. Please consider
this patch series for the next merge window.

Thanks,

Bart.

Link: https://lore.kernel.org/r/20240603172311.1587589-1-bvanassche@acm.org
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
  • Loading branch information
Martin K. Petersen committed Jun 5, 2024
2 parents 5074f48 + daf6133 commit f51b2db
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 8 deletions.
9 changes: 4 additions & 5 deletions drivers/scsi/arm/acornscsi.c
Original file line number Diff line number Diff line change
Expand Up @@ -2450,7 +2450,7 @@ static int acornscsi_queuecmd_lck(struct scsi_cmnd *SCpnt)
return 0;
}

DEF_SCSI_QCMD(acornscsi_queuecmd)
static DEF_SCSI_QCMD(acornscsi_queuecmd)

enum res_abort { res_not_running, res_success, res_success_clear, res_snooze };

Expand Down Expand Up @@ -2552,7 +2552,7 @@ static enum res_abort acornscsi_do_abort(AS_Host *host, struct scsi_cmnd *SCpnt)
* Params : SCpnt - command to abort
* Returns : one of SCSI_ABORT_ macros
*/
int acornscsi_abort(struct scsi_cmnd *SCpnt)
static int acornscsi_abort(struct scsi_cmnd *SCpnt)
{
AS_Host *host = (AS_Host *) SCpnt->device->host->hostdata;
int result;
Expand Down Expand Up @@ -2634,7 +2634,7 @@ int acornscsi_abort(struct scsi_cmnd *SCpnt)
* Params : SCpnt - command causing reset
* Returns : one of SCSI_RESET_ macros
*/
int acornscsi_host_reset(struct scsi_cmnd *SCpnt)
static int acornscsi_host_reset(struct scsi_cmnd *SCpnt)
{
AS_Host *host = (AS_Host *)SCpnt->device->host->hostdata;
struct scsi_cmnd *SCptr;
Expand Down Expand Up @@ -2679,8 +2679,7 @@ int acornscsi_host_reset(struct scsi_cmnd *SCpnt)
* Params : host - host to give information on
* Returns : a constant string
*/
const
char *acornscsi_info(struct Scsi_Host *host)
static const char *acornscsi_info(struct Scsi_Host *host)
{
static char string[100], *p;

Expand Down
2 changes: 1 addition & 1 deletion drivers/scsi/arm/cumana_2.c
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ cumanascsi_2_dma_stop(struct Scsi_Host *host, struct scsi_pointer *SCp)
* Params : host - driver host structure to return info for.
* Returns : pointer to a static buffer containing null terminated string.
*/
const char *cumanascsi_2_info(struct Scsi_Host *host)
static const char *cumanascsi_2_info(struct Scsi_Host *host)
{
struct cumanascsi2_info *info = (struct cumanascsi2_info *)host->hostdata;
static char string[150];
Expand Down
2 changes: 1 addition & 1 deletion drivers/scsi/arm/eesox.c
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@ eesoxscsi_dma_stop(struct Scsi_Host *host, struct scsi_pointer *SCp)
* Params : host - driver host structure to return info for.
* Returns : pointer to a static buffer containing null terminated string.
*/
const char *eesoxscsi_info(struct Scsi_Host *host)
static const char *eesoxscsi_info(struct Scsi_Host *host)
{
struct eesoxscsi_info *info = (struct eesoxscsi_info *)host->hostdata;
static char string[150];
Expand Down
2 changes: 1 addition & 1 deletion drivers/scsi/arm/powertec.c
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ powertecscsi_dma_stop(struct Scsi_Host *host, struct scsi_pointer *SCp)
* Params : host - driver host structure to return info for.
* Returns : pointer to a static buffer containing null terminated string.
*/
const char *powertecscsi_info(struct Scsi_Host *host)
static const char *powertecscsi_info(struct Scsi_Host *host)
{
struct powertec_info *info = (struct powertec_info *)host->hostdata;
static char string[150];
Expand Down

0 comments on commit f51b2db

Please sign in to comment.