€•0ZŒsphinx.addnodes”Œdocument”“”)”}”(Œ rawsource”Œ”Œchildren”]”(Œ translations”Œ LanguagesNode”“”)”}”(hhh]”(hŒ pending_xref”“”)”}”(hhh]”Œdocutils.nodes”ŒText”“”ŒChinese (Simplified)”…””}”Œparent”hsbaŒ attributes”}”(Œids”]”Œclasses”]”Œnames”]”Œdupnames”]”Œbackrefs”]”Œ refdomain”Œstd”Œreftype”Œdoc”Œ reftarget”Œ0/translations/zh_CN/filesystems/spufs/spu_create”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)”}”(hhh]”hŒChinese (Traditional)”…””}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ0/translations/zh_TW/filesystems/spufs/spu_create”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒItalian”…””}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ0/translations/it_IT/filesystems/spufs/spu_create”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒJapanese”…””}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ0/translations/ja_JP/filesystems/spufs/spu_create”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒKorean”…””}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ0/translations/ko_KR/filesystems/spufs/spu_create”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒSpanish”…””}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ0/translations/sp_SP/filesystems/spufs/spu_create”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubeh}”(h]”h ]”h"]”h$]”h&]”Œcurrent_language”ŒEnglish”uh1h hhŒ _document”hŒsource”NŒline”NubhŒcomment”“”)”}”(hŒ SPDX-License-Identifier: GPL-2.0”h]”hŒ SPDX-License-Identifier: GPL-2.0”…””}”hh£sbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1h¡hhhžhhŸŒJ/var/lib/git/docbuild/linux/Documentation/filesystems/spufs/spu_create.rst”h KubhŒsection”“”)”}”(hhh]”(hŒtitle”“”)”}”(hŒ spu_create”h]”hŒ spu_create”…””}”(hh»hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hh¶hžhhŸh³h Kubhµ)”}”(hhh]”(hº)”}”(hŒName”h]”hŒName”…””}”(hhÌhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hhÉhžhhŸh³h KubhŒ block_quote”“”)”}”(hŒ'spu_create - create a new spu context ”h]”hŒ paragraph”“”)”}”(hŒ%spu_create - create a new spu context”h]”hŒ%spu_create - create a new spu context”…””}”(hhâhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h K hhÜubah}”(h]”h ]”h"]”h$]”h&]”uh1hÚhŸh³h K hhÉhžhubeh}”(h]”Œname”ah ]”h"]”Œname”ah$]”h&]”uh1h´hh¶hžhhŸh³h Kubhµ)”}”(hhh]”(hº)”}”(hŒSynopsis”h]”hŒSynopsis”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hhþhžhhŸh³h K ubhÛ)”}”(hŒu:: #include #include int spu_create(const char *pathname, int flags, mode_t mode); ”h]”hŒ literal_block”“”)”}”(hŒj#include #include int spu_create(const char *pathname, int flags, mode_t mode);”h]”hŒj#include #include int spu_create(const char *pathname, int flags, mode_t mode);”…””}”hjsbah}”(h]”h ]”h"]”h$]”h&]”h±h²uh1jhŸh³h Khjubah}”(h]”h ]”h"]”h$]”h&]”uh1hÚhŸh³h Khhþhžhubeh}”(h]”Œsynopsis”ah ]”h"]”Œsynopsis”ah$]”h&]”uh1h´hh¶hžhhŸh³h K ubhµ)”}”(hhh]”(hº)”}”(hŒ Description”h]”hŒ Description”…””}”(hj4hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hj1hžhhŸh³h KubhÛ)”}”(hXÏThe spu_create system call is used on PowerPC machines that implement the Cell Broadband Engine Architecture in order to access Synergistic Processor Units (SPUs). It creates a new logical context for an SPU in pathname and returns a handle to associated with it. pathname must point to a non-existing directory in the mount point of the SPU file system (spufs). When spu_create is successful, a directory gets cre- ated on pathname and it is populated with files. The returned file handle can only be passed to spu_run(2) or closed, other operations are not defined on it. When it is closed, all associ- ated directory entries in spufs are removed. When the last file handle pointing either inside of the context directory or to this file descriptor is closed, the logical SPU context is destroyed. The parameter flags can be zero or any bitwise or'd combination of the following constants: SPU_RAWIO Allow mapping of some of the hardware registers of the SPU into user space. This flag requires the CAP_SYS_RAWIO capability, see capabilities(7). The mode parameter specifies the permissions used for creating the new directory in spufs. mode is modified with the user's umask(2) value and then used for both the directory and the files contained in it. The file permissions mask out some more bits of mode because they typically support only read or write access. See stat(2) for a full list of the possible mode values. ”h]”(há)”}”(hXàThe spu_create system call is used on PowerPC machines that implement the Cell Broadband Engine Architecture in order to access Synergistic Processor Units (SPUs). It creates a new logical context for an SPU in pathname and returns a handle to associated with it. pathname must point to a non-existing directory in the mount point of the SPU file system (spufs). When spu_create is successful, a directory gets cre- ated on pathname and it is populated with files.”h]”hXàThe spu_create system call is used on PowerPC machines that implement the Cell Broadband Engine Architecture in order to access Synergistic Processor Units (SPUs). It creates a new logical context for an SPU in pathname and returns a handle to associated with it. pathname must point to a non-existing directory in the mount point of the SPU file system (spufs). When spu_create is successful, a directory gets cre- ated on pathname and it is populated with files.”…””}”(hjFhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h KhjBubhá)”}”(hX[The returned file handle can only be passed to spu_run(2) or closed, other operations are not defined on it. When it is closed, all associ- ated directory entries in spufs are removed. When the last file handle pointing either inside of the context directory or to this file descriptor is closed, the logical SPU context is destroyed.”h]”hX[The returned file handle can only be passed to spu_run(2) or closed, other operations are not defined on it. When it is closed, all associ- ated directory entries in spufs are removed. When the last file handle pointing either inside of the context directory or to this file descriptor is closed, the logical SPU context is destroyed.”…””}”(hjThžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h K hjBubhá)”}”(hŒ\The parameter flags can be zero or any bitwise or'd combination of the following constants:”h]”hŒ^The parameter flags can be zero or any bitwise or’d combination of the following constants:”…””}”(hjbhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h K&hjBubhŒdefinition_list”“”)”}”(hhh]”hŒdefinition_list_item”“”)”}”(hŒSPU_RAWIO Allow mapping of some of the hardware registers of the SPU into user space. This flag requires the CAP_SYS_RAWIO capability, see capabilities(7). ”h]”(hŒterm”“”)”}”(hŒ SPU_RAWIO”h]”hŒ SPU_RAWIO”…””}”(hj}hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j{hŸh³h K,hjwubhŒ definition”“”)”}”(hhh]”há)”}”(hŒ’Allow mapping of some of the hardware registers of the SPU into user space. This flag requires the CAP_SYS_RAWIO capability, see capabilities(7).”h]”hŒ’Allow mapping of some of the hardware registers of the SPU into user space. This flag requires the CAP_SYS_RAWIO capability, see capabilities(7).”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h K*hjubah}”(h]”h ]”h"]”h$]”h&]”uh1j‹hjwubeh}”(h]”h ]”h"]”h$]”h&]”uh1juhŸh³h K,hjrubah}”(h]”h ]”h"]”h$]”h&]”uh1jphjBubhá)”}”(hX}The mode parameter specifies the permissions used for creating the new directory in spufs. mode is modified with the user's umask(2) value and then used for both the directory and the files contained in it. The file permissions mask out some more bits of mode because they typically support only read or write access. See stat(2) for a full list of the possible mode values.”h]”hXThe mode parameter specifies the permissions used for creating the new directory in spufs. mode is modified with the user’s umask(2) value and then used for both the directory and the files contained in it. The file permissions mask out some more bits of mode because they typically support only read or write access. See stat(2) for a full list of the possible mode values.”…””}”(hj°hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h K.hjBubeh}”(h]”h ]”h"]”h$]”h&]”uh1hÚhŸh³h Khj1hžhubeh}”(h]”Œ description”ah ]”h"]”Œ description”ah$]”h&]”uh1h´hh¶hžhhŸh³h Kubhµ)”}”(hhh]”(hº)”}”(hŒ Return Value”h]”hŒ Return Value”…””}”(hjÏhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjÌhžhhŸh³h K7ubhÛ)”}”(hŒ˜spu_create returns a new file descriptor. It may return -1 to indicate an error condition and set errno to one of the error codes listed below. ”h]”há)”}”(hŒ–spu_create returns a new file descriptor. It may return -1 to indicate an error condition and set errno to one of the error codes listed below.”h]”hŒ–spu_create returns a new file descriptor. It may return -1 to indicate an error condition and set errno to one of the error codes listed below.”…””}”(hjáhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h K8hjÝubah}”(h]”h ]”h"]”h$]”h&]”uh1hÚhŸh³h K8hjÌhžhubeh}”(h]”Œ return-value”ah ]”h"]”Œ return value”ah$]”h&]”uh1h´hh¶hžhhŸh³h K7ubhµ)”}”(hhh]”(hº)”}”(hŒErrors”h]”hŒErrors”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjýhžhhŸh³h K>ubhÛ)”}”(hXEACCES The current user does not have write access on the spufs mount point. EEXIST An SPU context already exists at the given path name. EFAULT pathname is not a valid string pointer in the current address space. EINVAL pathname is not a directory in the spufs mount point. ELOOP Too many symlinks were found while resolving pathname. EMFILE The process has reached its maximum open file limit. ENAMETOOLONG pathname was too long. ENFILE The system has reached the global open file limit. ENOENT Part of pathname could not be resolved. ENOMEM The kernel could not allocate all resources required. ENOSPC There are not enough SPU resources available to create a new context or the user specific limit for the number of SPU con- texts has been reached. ENOSYS the functionality is not provided by the current system, because either the hardware does not provide SPUs or the spufs module is not loaded. ENOTDIR A part of pathname is not a directory. ”h]”(jq)”}”(hhh]”jv)”}”(hŒOEACCES The current user does not have write access on the spufs mount point. ”h]”(j|)”}”(hŒEACCES”h]”hŒEACCES”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1j{hŸh³h KAhjubjŒ)”}”(hhh]”há)”}”(hŒGThe current user does not have write access on the spufs mount point.”h]”hŒGThe current user does not have write access on the spufs mount point.”…””}”(hj*hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h K@hj'ubah}”(h]”h ]”h"]”h$]”h&]”uh1j‹hjubeh}”(h]”h ]”h"]”h$]”h&]”uh1juhŸh³h KAhjubah}”(h]”h ]”h"]”h$]”h&]”uh1jphjubhá)”}”(hŒubhµ)”}”(hhh]”(hº)”}”(hŒNotes”h]”hŒNotes”…””}”(hjÃhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjÀhžhhŸh³h KeubhÛ)”}”(hŒíspu_create is meant to be used from libraries that implement a more abstract interface to SPUs, not to be used from regular applications. See http://www.bsc.es/projects/deepcomputing/linuxoncell/ for the rec- ommended libraries. ”h]”há)”}”(hŒëspu_create is meant to be used from libraries that implement a more abstract interface to SPUs, not to be used from regular applications. See http://www.bsc.es/projects/deepcomputing/linuxoncell/ for the rec- ommended libraries.”h]”(hŒ•spu_create is meant to be used from libraries that implement a more abstract interface to SPUs, not to be used from regular applications. See ”…””}”(hjÕhžhhŸNh NubhŒ reference”“”)”}”(hŒ5http://www.bsc.es/projects/deepcomputing/linuxoncell/”h]”hŒ5http://www.bsc.es/projects/deepcomputing/linuxoncell/”…””}”(hjßhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”jáuh1jÝhjÕubhŒ! for the rec- ommended libraries.”…””}”(hjÕhžhhŸNh Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h KfhjÑubah}”(h]”h ]”h"]”h$]”h&]”uh1hÚhŸh³h KfhjÀhžhubeh}”(h]”Œnotes”ah ]”h"]”Œnotes”ah$]”h&]”uh1h´hh¶hžhhŸh³h Keubhµ)”}”(hhh]”(hº)”}”(hŒFiles”h]”hŒFiles”…””}”(hj hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjhžhhŸh³h KmubhÛ)”}”(hŒnpathname must point to a location beneath the mount point of spufs. By convention, it gets mounted in /spu. ”h]”há)”}”(hŒlpathname must point to a location beneath the mount point of spufs. By convention, it gets mounted in /spu.”h]”hŒlpathname must point to a location beneath the mount point of spufs. By convention, it gets mounted in /spu.”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h Knhjubah}”(h]”h ]”h"]”h$]”h&]”uh1hÚhŸh³h Knhjhžhubeh}”(h]”Œfiles”ah ]”h"]”Œfiles”ah$]”h&]”uh1h´hh¶hžhhŸh³h Kmubhµ)”}”(hhh]”(hº)”}”(hŒ Conforming to”h]”hŒ Conforming to”…””}”(hj:hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hj7hžhhŸh³h KsubhÛ)”}”(hŒThis call is Linux specific and only implemented by the ppc64 architec- ture. Programs using this system call are not portable. ”h]”há)”}”(hŒThis call is Linux specific and only implemented by the ppc64 architec- ture. Programs using this system call are not portable.”h]”hŒThis call is Linux specific and only implemented by the ppc64 architec- ture. Programs using this system call are not portable.”…””}”(hjLhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h KthjHubah}”(h]”h ]”h"]”h$]”h&]”uh1hÚhŸh³h Kthj7hžhubeh}”(h]”Œ conforming-to”ah ]”h"]”Œ conforming to”ah$]”h&]”uh1h´hh¶hžhhŸh³h Ksubhµ)”}”(hhh]”(hº)”}”(hŒBugs”h]”hŒBugs”…””}”(hjkhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjhhžhhŸh³h KyubhÛ)”}”(hŒDThe code does not yet fully implement all features lined out here. ”h]”há)”}”(hŒBThe code does not yet fully implement all features lined out here.”h]”hŒBThe code does not yet fully implement all features lined out here.”…””}”(hj}hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h Kzhjyubah}”(h]”h ]”h"]”h$]”h&]”uh1hÚhŸh³h Kzhjhhžhubeh}”(h]”Œbugs”ah ]”h"]”Œbugs”ah$]”h&]”uh1h´hh¶hžhhŸh³h Kyubhµ)”}”(hhh]”(hº)”}”(hŒAuthor”h]”hŒAuthor”…””}”(hjœhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hj™hžhhŸh³h K~ubhÛ)”}”(hŒ!Arnd Bergmann ”h]”há)”}”(hŒ Arnd Bergmann ”h]”(hŒArnd Bergmann <”…””}”(hj®hžhhŸNh NubjÞ)”}”(hŒarndb@de.ibm.com”h]”hŒarndb@de.ibm.com”…””}”(hj¶hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”Œrefuri”Œmailto:arndb@de.ibm.com”uh1jÝhj®ubhŒ>”…””}”(hj®hžhhŸNh Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h Khjªubah}”(h]”h ]”h"]”h$]”h&]”uh1hÚhŸh³h Khj™hžhubeh}”(h]”Œauthor”ah ]”h"]”Œauthor”ah$]”h&]”uh1h´hh¶hžhhŸh³h K~ubhµ)”}”(hhh]”(hº)”}”(hŒSee Also”h]”hŒSee Also”…””}”(hjáhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h¹hjÞhžhhŸh³h K‚ubhÛ)”}”(hŒ/capabilities(7), close(2), spu_run(2), spufs(7)”h]”há)”}”(hjñh]”hŒ/capabilities(7), close(2), spu_run(2), spufs(7)”…””}”(hjóhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhŸh³h Kƒhjïubah}”(h]”h ]”h"]”h$]”h&]”uh1hÚhŸh³h KƒhjÞhžhubeh}”(h]”Œsee-also”ah ]”h"]”Œsee also”ah$]”h&]”uh1h´hh¶hžhhŸh³h K‚ubeh}”(h]”Œ spu-create”ah ]”h"]”Œ spu_create”ah$]”h&]”uh1h´hhhžhhŸh³h Kubeh}”(h]”h ]”h"]”h$]”h&]”Œsource”h³uh1hŒcurrent_source”NŒ current_line”NŒsettings”Œdocutils.frontend”ŒValues”“”)”}”(h¹NŒ generator”NŒ datestamp”NŒ source_link”NŒ source_url”NŒ toc_backlinks”Œentry”Œfootnote_backlinks”KŒ sectnum_xform”KŒstrip_comments”NŒstrip_elements_with_classes”NŒ strip_classes”NŒ report_level”KŒ halt_level”KŒexit_status_level”KŒdebug”NŒwarning_stream”NŒ traceback”ˆŒinput_encoding”Œ utf-8-sig”Œinput_encoding_error_handler”Œstrict”Œoutput_encoding”Œutf-8”Œoutput_encoding_error_handler”j9Œerror_encoding”Œutf-8”Œerror_encoding_error_handler”Œbackslashreplace”Œ language_code”Œen”Œrecord_dependencies”NŒconfig”NŒ id_prefix”hŒauto_id_prefix”Œid”Œ dump_settings”NŒdump_internals”NŒdump_transforms”NŒdump_pseudo_xml”NŒexpose_internals”NŒstrict_visitor”NŒ_disable_config”NŒ_source”h³Œ _destination”NŒ _config_files”]”Œ7/var/lib/git/docbuild/linux/Documentation/docutils.conf”aŒfile_insertion_enabled”ˆŒ raw_enabled”KŒline_length_limit”M'Œpep_references”NŒ pep_base_url”Œhttps://peps.python.org/”Œpep_file_url_template”Œpep-%04d”Œrfc_references”NŒ rfc_base_url”Œ&https://datatracker.ietf.org/doc/html/”Œ tab_width”KŒtrim_footnote_reference_space”‰Œsyntax_highlight”Œlong”Œ smart_quotes”ˆŒsmartquotes_locales”]”Œcharacter_level_inline_markup”‰Œdoctitle_xform”‰Œ docinfo_xform”KŒsectsubtitle_xform”‰Œ image_loading”Œlink”Œembed_stylesheet”‰Œcloak_email_addresses”ˆŒsection_self_link”‰Œenv”NubŒreporter”NŒindirect_targets”]”Œsubstitution_defs”}”Œsubstitution_names”}”Œrefnames”}”Œrefids”}”Œnameids”}”(jjhûhøj.j+jÉjÆjúj÷j½jºjjj4j1jejbj–j“jÛjØj juŒ nametypes”}”(j‰hû‰j.‰jɉjú‰j½‰j‰j4‰je‰j–‰jÛ‰j ‰uh}”(jh¶høhÉj+hþjÆj1j÷jÌjºjýjjÀj1jjbj7j“jhjØj™jjÞuŒ footnote_refs”}”Œ citation_refs”}”Œ autofootnotes”]”Œautofootnote_refs”]”Œsymbol_footnotes”]”Œsymbol_footnote_refs”]”Œ footnotes”]”Œ citations”]”Œautofootnote_start”KŒsymbol_footnote_start”KŒ id_counter”Œ collections”ŒCounter”“”}”…”R”Œparse_messages”]”Œtransform_messages”]”Œ transformer”NŒ include_log”]”Œ decoration”Nhžhub.