From: Asai Thambi S P Date: Wed, 30 May 2012 01:44:01 +0000 (-0700) Subject: mtip32xx: minor performance tweak X-Git-Tag: firefly_0821_release~3680^2~2704^2~3 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=377b8fc6d70aab90ccfc053630c65835defbc3f8;p=firefly-linux-kernel-4.4.55.git mtip32xx: minor performance tweak When checking for command completions if the register value is zero, proceed to next register. Signed-off-by: Asai Thambi S P Signed-off-by: Jens Axboe --- diff --git a/drivers/block/mtip32xx/mtip32xx.c b/drivers/block/mtip32xx/mtip32xx.c index cd271d5e1b73..29735316730a 100644 --- a/drivers/block/mtip32xx/mtip32xx.c +++ b/drivers/block/mtip32xx/mtip32xx.c @@ -970,6 +970,8 @@ static inline void mtip_process_sdbf(struct driver_data *dd) /* walk all bits in all slot groups */ for (group = 0; group < dd->slot_groups; group++) { completed = readl(port->completed[group]); + if (!completed) + continue; /* clear completed status register in the hardware.*/ writel(completed, port->completed[group]);