'\" t .\" Title: bitmap_fold .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: July 2017 .\" Manual: Basic Kernel Library Functions .\" Source: Kernel Hackers Manual 4.11.6 .\" Language: English .\" .TH "BITMAP_FOLD" "9" "July 2017" "Kernel Hackers Manual 4\&.11\&" "Basic Kernel Library Functions" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" bitmap_fold \- fold larger bitmap into smaller, modulo specified size .SH "SYNOPSIS" .HP \w'void\ bitmap_fold('u .BI "void bitmap_fold(unsigned\ long\ *\ " "dst" ", const\ unsigned\ long\ *\ " "orig" ", unsigned\ int\ " "sz" ", unsigned\ int\ " "nbits" ");" .SH "ARGUMENTS" .PP \fIunsigned long * dst\fR .RS 4 resulting smaller bitmap .RE .PP \fIconst unsigned long * orig\fR .RS 4 original larger bitmap .RE .PP \fIunsigned int sz\fR .RS 4 specified size .RE .PP \fIunsigned int nbits\fR .RS 4 number of bits in each of these bitmaps .RE .SH "DESCRIPTION" .PP For each bit oldbit in \fIorig\fR, set bit oldbit mod \fIsz\fR in \fIdst\fR\&. Clear all other bits in \fIdst\fR\&. See further the comment and Example [2] for \fBbitmap_onto\fR for why and how to use this\&. .SH "COPYRIGHT" .br