Selaa lähdekoodia

added trivial documentation

Ioannis Koutras 12 vuotta sitten
vanhempi
commit
2d9dc3bcd3
1 muutettua tiedostoa jossa 11 lisäystä ja 1 poistoa
  1. 11 1
      include/dmmlib/freelist/freelist.h

+ 11 - 1
include/dmmlib/freelist/freelist.h

@@ -47,7 +47,7 @@
  *
  * @param  raw_block The pointer of the freelist raw block.
  * @param  ptr       The pointer of the memory block to be re-allocated.
- * @param  size  The requested memory size.
+ * @param  size      The requested memory size.
  * @retval           The address to serve the request.
  * @retval NULL      No available memory space.
  */
@@ -62,6 +62,16 @@ void freelist_free(freelist_rb_t *raw_block, void *ptr);
 void * freelist_realloc(freelist_rb_t *raw_block, void *ptr, size_t size);
 
 #ifdef WITH_MEMALIGN
+/**
+ * Tries to allocate memory in an aligned address from a freelist-organized raw
+ * block.
+ *
+ * @param  raw_block The pointer of the freelist raw block.
+ * @param  alignment The alignment that you want to use for the memory.
+ * @param  size      The requested memory size, in bytes.
+ * @retval           The address to serve the request.
+ * @retval NULL      No available memory space.
+ */
 void * freelist_memalign(freelist_rb_t *raw_block, size_t alignment,
         size_t size);
 #endif /* WITH_MEMALIGN */