Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\decompress_bunzip2.c Create Date:2022-07-28 06:16:49
Last Modify:2020-03-15 22:49:38 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:Undo burrows-wheeler transform on intermediate buffer to produce output.If start_bunzip was initialized with out_fd =-1, then up to len bytes ofdata are written to outbuf. Return value is number of bytes written orerror (all errors are negative numbers)

Proto:static int __attribute__((__section__(".init.text"))) __attribute__((__cold__))read_bunzip(struct bunzip_data *bd, char *outbuf, int len)

Type:int

Parameter:

TypeParameterName
struct bunzip_data *bd
char *outbuf
intlen
529  If State for interrupting output loop < 0 Then Return State for interrupting output loop
532  gotcount = 0
533  dbuf = Intermediate buffer and its size (in bytes)
534  pos = State for interrupting output loop
535  xcurrent = State for interrupting output loop
541  If State for interrupting output loop Then
543  --State for interrupting output loop
545  cycle
548  If gotcount >= len Then
555  outbuf[gotcount++] = xcurrent
563  Continue
566  If Not State for interrupting output loop -- Then Break
570  previous = xcurrent
571  pos = dbuf[pos]
572  xcurrent = pos & 0xff
573  pos >>= 8
581  Else
597  The CRC values stored in the block header and calculated from thedata = ~The CRC values stored in the block header and calculated from thedata
598  The CRC values stored in the block header and calculated from thedata = ( The CRC values stored in the block header and calculated from thedata << 1 | The CRC values stored in the block header and calculated from thedata >> 31 ) ^ The CRC values stored in the block header and calculated from thedata
603  Return RETVAL_LAST_BLOCK
610  previous = Unpacks the next block and sets up for the inverse burrows-wheeler step.
611  If previous Then
612  State for interrupting output loop = previous
613  Return If previous != RETVAL_LAST_BLOCK Then previous Else gotcount
615  The CRC values stored in the block header and calculated from thedata = 0xffffffffUL
616  pos = State for interrupting output loop
617  xcurrent = State for interrupting output loop
618  Go to decode_next_byte
Caller
NameDescribe
bunzip2Example usage: decompress src_fd to dst_fd. (Stops at end of bzip2 data,not end of file.)