struct ieee80211_duration *dn, int *npktp)
struct ieee80211_duration *dn, int *npktp, int debug)
ieee80211_compute_duration(struct ieee80211_frame *wh, int paylen,    uint32_t flags, int fraglen, int rate, struct ieee80211_duration *d0,    struct ieee80211_duration *dn, int *npktp){	int rc;	int firstlen, hdrlen, lastlen, lastlen0, npkt, overlen;	if ((wh->i_fc[1] & IEEE80211_FC1_DIR_MASK) == IEEE80211_FC1_DIR_DSTODS)		hdrlen = sizeof(struct ieee80211_frame_addr4);	else		hdrlen = sizeof(struct ieee80211_frame);	if ((flags & IEEE80211_F_WEPON) != 0) {		overlen = IEEE80211_WEP_TOTLEN + IEEE80211_CRC_LEN;#if 0	/* 802.11 lets us extend a fragment's length by the length of	 * a WEP header, AFTER fragmentation.  Might want to disable	 * this while fancy link adaptations are running.	 */		fraglen -= IEEE80211_WEP_TOTLEN;#endif#if 0	/* Ditto CRC? */		fraglen -= IEEE80211_CRC_LEN;#endif	} else		overlen = IEEE80211_CRC_LEN;	npkt = paylen / fraglen;	lastlen0 = paylen % fraglen;	if (npkt == 0) {		/* no fragments */		lastlen = paylen + overlen;	} else if (lastlen0 != 0) {		/* a short fragment */		lastlen = lastlen0 + overlen;		npkt++;	} else		lastlen = fraglen + overlen;	if (npktp != NULL)		*npktp = npkt;	if (npkt > 1)		firstlen = fraglen + overlen;	else		firstlen = paylen + overlen;	rc = ieee80211_compute_duration1(firstlen + hdrlen, flags, rate, d0);	if (rc == -1)		return rc;	if (npkt > 1) {		*dn = *d0;		return 0;	}	return ieee80211_compute_duration1(lastlen + hdrlen, flags, rate, dn);}