2 .\" Copyright (c) 2001 by Sun Microsystems, Inc. All rights reserved.
3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
5 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 .TH RSM_MEMSEG_EXPORT_PUBLISH 3RSM "Jun 8, 2001"
8 rsm_memseg_export_publish, rsm_memseg_export_unpublish,
9 rsm_memseg_export_republish \- allow or disallow a memory segment to be
10 imported by other nodes
14 cc [ \fIflag\fR... ] \fIfile\fR... -lrsm [ \fIlibrary\fR... ]
17 \fBint\fR \fBrsm_memseg_export_publish\fR(
18 \fBrsm_memseg_export_handle_t\fR \fImemseg\fR,
19 \fBrsm_memseg_id_t *\fR\fIsegment_id\fR,
20 \fBrsmapi_access_entry_t\fR \fIaccess_list\fR[],
21 \fBuint_t\fR \fIaccess_list_length\fR);
26 \fBint\fR \fBrsm_memseg_export_unpublish\fR(
27 \fBrsm_memseg_export_handle_t\fR \fImemseg\fR);
32 \fBint\fR \fBrsm_memseg_export_republish\fR(
33 \fBrsm_memseg_export_handle_t\fR \fImemseg\fR,
34 \fBrsmapi_access_entry_t\fR \fIaccess_list\fR[],
35 \fBuint_t\fR \fIaccess_list_length\fR);
41 The \fBrsm_memseg_export_publish()\fR, \fBrsm_memseg_export_unpublish()\fR, and
42 \fBrsm_memseg_export_republish()\fR functions allow or disallow a memory
43 segment to be imported by other nodes.
46 The rsm_memseg_export_publish(3RSM) function allows the export segment
47 specified by the \fImemseg\fR argument to be imported by other nodes. It also
48 assigns a unique segment identifier to the segment and defines the access
49 control list for the segment. The \fIsegment_id\fR argument is a pointer to an
50 identifier which is unique on the publishing node. It is the responsibility of
51 the application to manage the assignment of unique segment identifiers. The
52 identifier can be optionally initialized to 0, in which case the system will
53 return a unique segment identifier value. The \fIaccess_list\fR argument is
54 composed of pairs of nodeid and access permissions. For each nodeid specified
55 in the list, the associated read/write permissions are provided by three octal
56 digits for owner, group, and other, as for Solaris file permissions. In the
57 access control each octal digit may have the following values:
87 An access permissions value of 0624 specifies: (1) an importer with the same
88 uid as the exporter has read and write access; (2) an importer with the same
89 gid as the exporter has write access only; and (3) all other importers have
90 read access only. When an access control list is provided, nodes not included
91 in the list will be prevented from importing the segment. However, if the
92 access list is \fINULL\fR (this will require the length
93 \fIaccess_list_length\fR to be specified as 0 as well), then no nodes will be
94 excluded from importing and the access permissions on all nodes will equal the
95 owner-group-other file creation permissions of the exporting process.
96 Corresponding to the \fIaccess_list\fR argument, the \fIaccess_list_length\fR
97 argument specifies the number of entries in the \fIaccess_list\fR array.
100 The \fBrsm_memseg_export_unpublish()\fR function disallows the export segment
101 specified by \fImemseg\fR from being imported. All the existing import
102 connections are forcibly disconnected.
105 The \fBrsm_memseg_export_republish()\fR function changes the access control
106 list for the exported and published segment. Although the current import
107 connections remain unaffected by this call, new connections are constrained by
112 Upon successful completion, these functions return 0. Otherwise, an error value
113 is returned to indicate the error.
117 The \fBrsm_memseg_export_publish()\fR, \fBrsm_memseg_export_unpublish()\fR, and
118 \fBrsm_memseg_export_republish()\fR functions can return the following errors:
122 \fB\fBRSMERR_BAD_SEG_HNDL\fR \fR
125 Invalid segment handle.
131 \fB\fBRSMERR_NOT_CREATOR\fR \fR
134 Not creator of segment.
139 The \fBrsm_memseg_export_publish()\fR and \fBrsm_memseg_export_republish()\fR
140 functions can return the following errors, with the exception that only
141 \fBrsm_memseg_export_publish()\fR can return the errors related to the segment
146 \fB\fBRSMERR_SEGID_IN_USE\fR \fR
150 Segment identifier in use.
156 \fB\fBRSMERR_RESERVED_SEGID\fR \fR
160 Segment identifier reserved.
166 \fB\fBRSMERR_BAD_SEGID\fR \fR
170 Invalid segment identifier.
176 \fB\fBRSMERR_BAD_ACL\fR \fR
180 Invalid access control list.
186 \fB\fBRSMERR_SEG_ALREADY_PUBLISHED\fR \fR
190 Segment already published.
196 \fB\fBRSMERR_INSUFFICIENT_MEM\fR \fR
206 \fB\fBRSMERR_INSUFFICIENT_RESOURCES\fR \fR
210 Insufficient resources.
216 \fB\fBRSMERR_LOCKS_NOT_SUPPORTED\fR \fR
226 \fB\fBRSMERR_BAD_ADDR\fR \fR
235 The \fBrsm_memseg_export_republish()\fR and \fBrsm_memseg_export_unpublish()\fR
236 functions can return the following errors:
240 \fB\fBRSMERR_SEG_NOT_PUBLISHED\fR \fR
243 Segment not published.
249 \fB\fBRSMERR_INTERRUPTED\fR\fR
252 The operation was interrupted by a signal.
258 See \fBattributes\fR(5) for descriptions of the following attributes:
266 ATTRIBUTE TYPE ATTRIBUTE VALUE
268 Interface Stability Evolving
276 \fBrsm_memseg_export_create\fR(3RSM), \fBattributes\fR(5)
280 An attempt to publish a segment might block until sufficient resources become