man pages section 9: DDI and DKI Kernel Functions

Exit Print View

Updated: July 2014
 
 

bzero(9F)

Name

bzero - clear memory for a given number of bytes

Synopsis

#include <sys/types.h>
#include <sys/ddi.h>

void bzero(void *addr, size_t bytes);

Interface Level

Architecture independent level 1 (DDI/DKI).

Parameters

addr

Starting virtual address of memory to be cleared.

bytes

The number of bytes to clear starting at addr.

Description

The bzero() function clears a contiguous portion of memory by filling it with zeros.

Context

The bzero() function can be called from user, interrupt, or kernel context.

See Also

bcopy(9F), clrbuf(9F), kmem_zalloc(9F)

Writing Device Drivers for Oracle Solaris 11.2

Warnings

The address range specified must be within the kernel space. No range checking is done. If an address outside of the kernel space is selected, the driver may corrupt the system in an unpredictable way.