2 Copyright © 1995-2017, The AROS Development Team. All rights reserved.
6 #include <proto/exec.h>
7 #include <exec/memory.h>
9 #include "partition_intern.h"
10 #include "partition_support.h"
13 /*****************************************************************************
16 #include <libraries/partition.h>
18 AROS_LH1(void, CloseRootPartition
,
21 AROS_LHA(struct PartitionHandle
*, ph
, A1
),
24 struct Library
*, PartitionBase
, 6, Partition
)
27 Close a root handle allocated by OpenRootPartition().
30 ph - root handle created by OpenRootPartition()
44 *****************************************************************************/
50 struct PTFunctionTable
*handler
= ph
->table
->handler
;
52 if (handler
->closePartitionTable
)
53 handler
->closePartitionTable(PartitionBase
, ph
);
56 CloseDevice((struct IORequest
*)ph
->bd
->ioreq
);
57 DeleteIORequest((struct IORequest
*)ph
->bd
->ioreq
);
58 DeleteMsgPort(ph
->bd
->port
);
59 FreeMem(ph
->bd
, sizeof(struct PartitionBlockDevice
));
60 FreeMem(ph
, sizeof(struct PartitionHandle
));