Re: [PATCH 2.6.16-rc6] Promise SuperTrak driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Mar 13, 2006 at 03:42:36PM -0800, Andrew Morton wrote:
> > +#include <linux/irq.h>
> 
> Can't include linux/irq.h from generic code (we really ought to fix that).

In a sense we have -- everybody should include <linux/interrupt.h> and
not <*/irq.h>.  Perhaps we need to poison the includes.

> > +static inline u16 shasta_alloc_tag(u32 *bitmap)
> > +{
> > +	u16 i;
> > +	for (i = 0; i < TAG_BITMAP_LENGTH; i++) 
> > +		if (!((*bitmap) & (1 << i))) {
> > +			*bitmap |= (1 << i);
> > +			return i;
> > +		}
> > +
> > +	return TAG_BITMAP_LENGTH;
> > +}
> 
> This is too large to be inlined.

And if I read the driver right, is unnecessary code.  It could just use
the midlayer tag code (ok, not scsi_populate_tag_msg() which is
SPI-specific, but scsi_activate_tcq(), scsi_deactivate_tcq(),
scsi_find_tag(), scsi_set_tag_type(), and scsi_get_tag_type() should all
work, being thin wrappers around the block layer functionality.

-
: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux