<!-- Generated by tools/generate_docs.py. Do not edit. -->

# `MC_fsOpen`

Open or create a file according to the supplied flags and access mode.

## Prototype

```c
M_Int32 MC_fsOpen(M_Char *name, M_Int32 flag, M_Int32 aMode);
```

### M_Int32 MC_fsOpen(M_Char \*name, M_Int32 flag, M_Int32 aMode)

Open or create a file according to the supplied flags and access mode. 

**API level**
: WIPI-C 1.2.1, ordinal 46. 

**Documentation status**
: draft. 

* **Parameters:**
  * **name** – File path in the selected install profile’s filesystem namespace. 
  * **flag** – Open flags. 
  * **aMode** – Access mode. 
* **Returns:**
  A file descriptor or the provider-defined failure value. 

## Catalog identity

| Field                | Value                                                  |
|----------------------|--------------------------------------------------------|
| API level            | `1.2.1`                                                |
| Family               | [`MC_FS`](https://mirusu400.github.io/libwipi/latest/generated/api/1.2.1/families/filesystem.md) |
| Ordinal              | 46                                                     |
| Documentation        | `draft`                                                |
| Implementation class | `table`                                                |
| ABI class            | `word-tail`                                            |

## Usage

### Parameters

| Name    | Meaning                                                           |
|---------|-------------------------------------------------------------------|
| `name`  | File path in the selected install profile’s filesystem namespace. |
| `flag`  | Open flags.                                                       |
| `aMode` | Access mode.                                                      |

### Return value

A file descriptor or the provider-defined failure value.

## Profile availability

API membership, device ABI, and install profile are independent. The rows below
describe libwipi implementation evidence, not platform-wide WIPI requirements.

| ABI profile                 | Install profile        | Current evidence                                  |
|-----------------------------|------------------------|---------------------------------------------------|
| `host-sim`                  | `none`                 | headers only                                      |
| `ktf-samsung`               | `none`                 | linkable generated veneer                         |
| `ktf-samsung`               | `aram-ktf`             | linkable generated veneer                         |
| `ktf-samsung`               | `sch-w8300-qpst-probe` | linkable generated veneer; named-device candidate |
| `lgt-raptor`                | `aram-raptor`          | observed in the scoped emulator suite             |
| `lgt-raptor`                | `aram-wie-raptor`      | declared; no confirmed adapter                    |
| `skt-samsung-sch-w830-dl21` | `none`                 | linkable exact-device fixed-root veneer           |

## Compiled examples

- [Filesystem](https://mirusu400.github.io/libwipi/latest/generated/examples/filesystem.md)

## Evidence boundary

Samsung/KTF selector confidence: `confirmed`. Catalog evidence: `anycall_magichole:analysis/decompiled/wipi_mc_fs_spec_adapter.c:540`.
