From: Jarod Wilson Date: Wed, 23 Jan 2008 21:05:45 +0000 (-0500) Subject: firewire: replace subtraction with bitwise and X-Git-Tag: v2.6.25-rc1~1133^2~2 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=8f9f963e5d9853dbc5fa5091f15ae64f423d3d89;p=linux-2.6 firewire: replace subtraction with bitwise and Replace an unnecessary subtraction with a bitwise AND when determining the value of ext_tcode in fw_fill_transaction() to save a cpu cycle or two in a somewhat critical path. Signed-off-by: Jarod Wilson Signed-off-by: Stefan Richter --- diff --git a/drivers/firewire/fw-transaction.c b/drivers/firewire/fw-transaction.c index 8018c3b9df..7fcc59dedf 100644 --- a/drivers/firewire/fw-transaction.c +++ b/drivers/firewire/fw-transaction.c @@ -153,7 +153,7 @@ fw_fill_request(struct fw_packet *packet, int tcode, int tlabel, int ext_tcode; if (tcode > 0x10) { - ext_tcode = tcode - 0x10; + ext_tcode = tcode & ~0x10; tcode = TCODE_LOCK_REQUEST; } else ext_tcode = 0;