Skip to content

Commit

Permalink
staging: ft1000: Remove unnecessary check in write_blk_fifo().
Browse files Browse the repository at this point in the history
byte_length = word_length * 4;

if (byte_length % 4) ...

word_length * 4 is always aligned at 4 bytes. Remove pointless
check.

Signed-off-by: Marek Belisko <marek.belisko@open-nandra.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Marek Belisko authored and Greg Kroah-Hartman committed Feb 9, 2011
1 parent 677aaa4 commit bcd2d92
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions drivers/staging/ft1000/ft1000-usb/ft1000_download.c
Original file line number Diff line number Diff line change
Expand Up @@ -644,16 +644,9 @@ static u32 write_blk_fifo(struct ft1000_device *ft1000dev, u16 **pUsFile,
{
u32 Status = STATUS_SUCCESS;
int byte_length;
long aligncnt;

byte_length = word_length * 4;

if (byte_length % 4)
aligncnt = 4 - (byte_length % 4);
else
aligncnt = 0;
byte_length += aligncnt;

if (byte_length && ((byte_length % 64) == 0))
byte_length += 4;

Expand Down

0 comments on commit bcd2d92

Please sign in to comment.