Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
usercopy.c File Reference
#include <asm/uaccess.h>

Go to the source code of this file.

Macros

#define __do_strncpy_from_user(dst, src, count, res)
 
#define __do_clear_user(addr, size)
 

Functions

unsigned long __generic_copy_to_user (void *to, const void *from, unsigned long n)
 
unsigned long __generic_copy_from_user (void *to, const void *from, unsigned long n)
 
long __strncpy_from_user (char *dst, const char *src, long count)
 
long strncpy_from_user (char *dst, const char *src, long count)
 
unsigned long __clear_user (void *to, unsigned long n)
 
unsigned long clear_user (void *to, unsigned long n)
 
long strnlen_user (const char *s, long n)
 

Macro Definition Documentation

#define __do_clear_user (   addr,
  size 
)
Value:
do { \
int w; \
asm volatile( \
" cmp 0,%0\n" \
" beq 1f\n" \
" clr %1\n" \
"0: movbu %1,(%3,%2)\n" \
" inc %3\n" \
" cmp %0,%3\n" \
" bne 0b\n" \
"1:\n" \
" sub %3,%0\n" \
"2:\n" \
".section .fixup,\"ax\"\n" \
"3: jmp 2b\n" \
".previous\n" \
".section __ex_table,\"a\"\n" \
" .balign 4\n" \
" .long 0b,3b\n" \
".previous\n" \
: "+r"(size), "=&r"(w) \
: "a"(addr), "d"(0) \
: "memory", "cc"); \
} while (0)

Definition at line 89 of file usercopy.c.

#define __do_strncpy_from_user (   dst,
  src,
  count,
  res 
)

Definition at line 33 of file usercopy.c.

Function Documentation

unsigned long __clear_user ( void to,
unsigned long  n 
)

Definition at line 116 of file usercopy.c.

unsigned long __generic_copy_from_user ( void to,
const void from,
unsigned long  n 
)

Definition at line 23 of file usercopy.c.

unsigned long __generic_copy_to_user ( void to,
const void from,
unsigned long  n 
)

Definition at line 15 of file usercopy.c.

long __strncpy_from_user ( char dst,
const char src,
long  count 
)

Definition at line 69 of file usercopy.c.

unsigned long clear_user ( void to,
unsigned long  n 
)

Definition at line 123 of file usercopy.c.

long strncpy_from_user ( char dst,
const char src,
long  count 
)

Definition at line 77 of file usercopy.c.

long strnlen_user ( const char s,
long  n 
)

Definition at line 135 of file usercopy.c.