On Thu, Oct 19, 2006 at 01:12:42AM +1000, Nick Piggin wrote:
> Matthew Wilcox wrote:
>
> >I also addressed the potential issue with nested attempts to block.
> >Now pci_block_user_cfg_access() can return -EBUSY if it's already blocked,
> >and pci_unblock_user_cfg_access() will WARN if you try to unblock an
> >already unblocked device.
>
> Why not just WARN if it is already blocked as well? Presumably if the
Because the driver can check the return value and fail the higher level
operation.
> driver needs nested blocking, it is going to have to carry some state
> to know when to do the final unblock anyway, so it may as well just
> not do these redundant blocks either.
No driver needs nested blocking, but blocks may be imposed on a driver's
device by the PCI core, for example.
> ** or ** just do a counting block/unblock to properly support nesting
> them. That is, go one way or the other, and do it properly.
I don't think that's necessary. Right now, we have one user (IPR's
BIST) and I'm trying to add a second (D-state transitions). We don't
need nested blocks, but we do need to fail in the highly unlikely case
someone tries to do them.
If it turns out we actually need them later, let's revisit this when we
have a user.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]