iwmbtfw(8): don't program hardware without existing firmware image
One should not start firmware update sequence just to understand
that there is no firmware image to program: update sequence for 7260
requires leaving manufacturing mode and in the case of missing
firmware file it will trigger complete re-initialization of BT adapter.
Which, in turn, will make the USB device to go away and reappear.
Since devd(8) has hooks for USB device attachment, in the case
of missing firmware it used to
- trigger the (failing) firmware download,
- which triggers device reset,
- which creates USB notification and devd(8) kicks back in.
Nice infinite cycle with many notifications via syslog:
{{{
Jan 3 09:00:01 kernel: ugen0.2: <vendor 0x8087 product 0x0a2a> at usbus0
Jan 3 09:00:01 kernel: ugen0.2: <vendor 0x8087 product 0x0a2a> at usbus0 (disconnected)
Jan 3 09:00:02 kernel: ugen0.2: <vendor 0x8087 product 0x0a2a> at usbus0
Jan 3 09:00:02 kernel: ugen0.2: <vendor 0x8087 product 0x0a2a> at usbus0 (disconnected)
}}}
Signed-off-by: Eygene Ryabinkin <rea@FreeBSD.org>
Reviewed by: wulf
MFC after: 1 month