Skip to content

Commit

Permalink
[PATCH] spi: remove fastcall crap
Browse files Browse the repository at this point in the history
gcc4 generates warnings when a non-FASTCALL function pointer is assigned to a
FASTCALL one.  Perhaps it has taste.

Cc: David Brownell <david-b@pacbell.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Andrew Morton authored and Greg Kroah-Hartman committed Jan 14, 2006
1 parent 7111763 commit 5d870c8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
7 changes: 6 additions & 1 deletion drivers/spi/spi.c
Original file line number Diff line number Diff line change
Expand Up @@ -480,6 +480,11 @@ EXPORT_SYMBOL_GPL(spi_busnum_to_master);

/*-------------------------------------------------------------------------*/

static void spi_complete(void *arg)
{
complete(arg);
}

/**
* spi_sync - blocking/synchronous SPI data transfers
* @spi: device with which data will be exchanged
Expand Down Expand Up @@ -508,7 +513,7 @@ int spi_sync(struct spi_device *spi, struct spi_message *message)
DECLARE_COMPLETION(done);
int status;

message->complete = (void (*)(void *)) complete;
message->complete = spi_complete;
message->context = &done;
status = spi_async(spi, message);
if (status == 0)
Expand Down
2 changes: 1 addition & 1 deletion include/linux/spi/spi.h
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ struct spi_message {
*/

/* completion is reported through a callback */
void FASTCALL((*complete)(void *context));
void (*complete)(void *context);
void *context;
unsigned actual_length;
int status;
Expand Down

0 comments on commit 5d870c8

Please sign in to comment.