Rev 1964 | Rev 1970 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1964 | Rev 1968 | ||
---|---|---|---|
Line 110... | Line 110... | ||
110 | if (n != 0 && size > ULONG_MAX / n) |
110 | if (n != 0 && size > ULONG_MAX / n) |
111 | return NULL; |
111 | return NULL; |
112 | return kzalloc(n * size, 0); |
112 | return kzalloc(n * size, 0); |
113 | } |
113 | } |
Line -... | Line 114... | ||
- | 114 | ||
- | 115 | extern const char hex_asc[]; |
|
- | 116 | #define hex_asc_lo(x) hex_asc[((x) & 0x0f)] |
|
- | 117 | #define hex_asc_hi(x) hex_asc[((x) & 0xf0) >> 4] |
|
- | 118 | ||
- | 119 | static inline char *pack_hex_byte(char *buf, u8 byte) |
|
- | 120 | { |
|
- | 121 | *buf++ = hex_asc_hi(byte); |
|
- | 122 | *buf++ = hex_asc_lo(byte); |
|
- | 123 | return buf; |
|
- | 124 | } |
|
- | 125 | ||
114 | 126 | ||
Line 115... | Line 127... | ||
115 | void free (void *ptr); |
127 | void free (void *ptr); |
Line 116... | Line 128... | ||
116 | 128 |