]> Chaos Git - corbenik/ctrulib.git/commitdiff
documentation for the soc service
authorLectem <lectem@gmail.com>
Thu, 27 Aug 2015 20:55:15 +0000 (16:55 -0400)
committerLectem <lectem@gmail.com>
Fri, 28 Aug 2015 18:55:40 +0000 (14:55 -0400)
libctru/include/3ds/services/soc.h

index 3ec99b72ea4e8de7e20aaca8da6d441939fa312b..34a8e49504832189f52ab27dc2bf1d5c3d344664 100644 (file)
@@ -1,7 +1,23 @@
+/**
+ * @file soc.h
+ * @brief SOC service for sockets communications
+ *
+ * After initializing this service you will be able to use system calls from netdb.h, sys/socket.h etc.
+ */
 #pragma once
 
-Result SOC_Initialize(u32 *context_addr, u32 context_size);//Example context_size: 0x48000. The specified context buffer can no longer be accessed by the process which called this function, since the userland permissions for this block are set to no-access.
+/**
+ * @brief Initializes the SOC service.
+ * @param context_addr Address of a page-aligned (0x1000) buffer to be used.
+ * @param context_size Size of the buffer, a multiple of 0x1000.
+ * @note The specified context buffer can no longer be accessed by the process which called this function, since the userland permissions for this block are set to no-access.
+ */
+Result SOC_Initialize(u32 *context_addr, u32 context_size);
 
+/**
+ * @brief Closes the soc service.
+ * @note You need to call this in order to be able to use the buffer again.
+ */
 Result SOC_Shutdown(void);
 
 /* this is supposed to be in unistd.h but newlib only puts it for cygwin */