2 Copyright © 2011-2017, The AROS Development Team. All rights reserved.
6 #include <proto/utility.h>
8 #include "partition_support.h"
11 /*****************************************************************************
14 #include <utility/tagitem.h>
15 #include <libraries/partition.h>
17 AROS_LH2(void, GetFileSystemAttrsA
,
20 AROS_LHA(struct Node
*, handle
, A1
),
21 AROS_LHA(const struct TagItem
*, taglist
, A2
),
24 struct Library
*, PartitionBase
, 22, Partition
)
27 get attributes of a partition table
30 handle - Filesystem handle
31 taglist - list of attributes; unknown tags are ignored
34 FST_ID (ULONG *) - Get 4-character FS ID
35 FST_NAME (STRPTR *) - Get a pointer to FS name
36 FST_FSENTRY (struct FileSysEntry *) - Fill in given FileSysEntry.
42 Name is returned as a pointer to an internally allocated string. You
43 should copy it if you want to keep it after the filesystem's
44 partition table handle has been closed.
46 The following fields in struct FileSysEntry will not be filled in:
50 You need to query for the filesystem's name separately and copy it
51 into a BSTR yourself, if you need to. Loading the handler is done by
52 the LoadFileSystem() function.
63 *****************************************************************************/
67 const struct FSFunctionTable
*handler
= ((struct FileSysHandle
*)handle
)->handler
;
70 while ((tag
= NextTagItem((struct TagItem
**)&taglist
)))
72 handler
->getFileSystemAttr(PartitionBase
, (struct FileSysHandle
*)handle
, tag
);
75 * TODO: handler returns TRUE if it knows the attribute and FALSE otherwise.
76 * If we ever have more partition table types which can handle embedded
77 * filesystem handlers, this can be expanded similar to GetPartitionAttrs(),
78 * and we will have some generic code here.