tail head cat sleep
QR code linking to this page

Manual Pages  — STORE

NAME

store, subyte, suswintr, suword – store data to user-space

CONTENTS

SYNOPSIS

#include <sys/types.h>
#include <sys/time.h>
#include <sys/systm.h>

int
subyte(volatile void *base, int byte);

int
suword(volatile void *base, long word);

int
suword16(volatile void *base, int word);

int
suword32(volatile void *base, int32_t word);

int
suword64(volatile void *base, int64_t word);
#include <sys/resourcevar.h>

int
suswintr(void *base, int word);

DESCRIPTION

The store functions are designed to copy small amounts of data to user-space. If write is successful, it is performed atomically. The data written must be naturally aligned.

The store routines provide the following functionality:
subyte()
  Stores a byte of data to the user-space address base.
suword()
  Stores a word of data to the user-space address base.
suword16()
  Stores 16 bits of data to the user-space address base.
suword32()
  Stores 32 bits of data to the user-space address base.
suword64()
  Stores 64 bits of data to the user-space address base.
suswintr()
  Stores a short word of data to the user-space address base. This function is safe to call during an interrupt context.

RETURN VALUES

The store functions return 0 on success or -1 on failure.

SEE ALSO

copy(9), fetch(9)

STORE (9) October 29, 2014

tail head cat sleep
QR code linking to this page


Please direct any comments about this manual page service to Ben Bullock. Privacy policy.

As soon as we started programming, we found to our surprise that it wasn't as easy to get programs right as we had thought. Debugging had to be discovered. I can remember the exact instant when I realized that a large part of my life from then on was going to be spent in finding mistakes in my own programs.
— Maurice Wilkes