Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Next »

void  FSDev_PartitionInit (CPU_CHAR    *name_dev,
                           FS_SEC_QTY   partition_size,
                           FS_ERR      *p_err);

File

Called from

Code enabled by

fs_dev.c

Application

not FS_CFG_RD_ONLY_EN

Initialize the partition structure on a device. See also section 7-5 “Partitions”.

Arguments

name_dev

Device name.

partition_size

Size of partition, in sectors. OR

0, if partition will occupy entire device.

p_err

Pointer to variable that will receive the return error code from this function.

FS_ERR_NONE

Partition structure initialized.

FS_ERR_DEV_VOL_OPEN

Volume open on device.

FS_ERR_INVALID_SEC_NBR

Sector start or count invalid.

FS_ERR_NAME_NULL

Argument name_dev passed a NULL pointer.

Or device access error (see section B-4 “Device Error Codes”).

Returned Value

None.

Notes/Warnings

  • Function blocked if a volume is open on the device. All volume (and files) must be closed prior to initializing the partition structure, since it will obliterate any existing file system.
  • Device state change will result from device I/O, not present or timeout error.
  • No labels