Date: Thu, 10 Jan 2008 23:55:56 GMT From: Steve Wise <swise@FreeBSD.org> To: Perforce Change Reviews <perforce@FreeBSD.org> Subject: PERFORCE change 133000 for review Message-ID: <200801102355.m0ANtuAJ040666@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=133000 Change 133000 by swise@swise:vic10:iwarp on 2008/01/10 23:55:35 Fixed genpoll allocator. It wasn't correctly computing the address to return. Affected files ... .. //depot/projects/iwarp/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cxio_hal.h#7 edit Differences ... ==== //depot/projects/iwarp/sys/dev/cxgb/ulp/iw_cxgb/iw_cxgb_cxio_hal.h#7 (text+ko) ==== @@ -255,7 +255,7 @@ if (blkno == SWAPBLK_NONE) return (0); - return (gp->gen_base + blkno); + return (gp->gen_base + ((1 << gp->gen_chunk_shift) * blkno)); } #define cxio_wait(ctx, lockp, cond) \ @@ -281,7 +281,7 @@ daddr_t blkno; chunks = size >> gp->gen_chunk_shift; - blkno = address - gp->gen_base; + blkno = (address - gp->gen_base) / (1 << gp->gen_chunk_shift); blist_free(gp->gen_list, blkno, chunks); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200801102355.m0ANtuAJ040666>