Laurent Pinchart
5c85e70240
libcamera: base: Rename FileDescriptor to SharedFD
...
Now that we have a UniqueFD class, the name FileDescriptor is ambiguous.
Rename it to SharedFD.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com >
Reviewed-by: Hirokazu Honda <hiroh@chromium.org >
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org >
2021-12-04 23:05:05 +02:00
Hirokazu Honda
edd70612e5
libcamera: file: Manage fd by UniqueFD
...
Manages the file descriptor owned by File by UniqueFD.
Signed-off-by: Hirokazu Honda <hiroh@chromium.org >
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com >
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org >
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com >
2021-12-04 23:05:01 +02:00
Laurent Pinchart
6a8582dc20
libcamera: file: Turn MapFlag and OpenModeFlag into enum class
...
Add type safety by turning the MapFlag and OpenModeFlag enum into enum
class.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com >
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org >
2021-08-03 10:55:33 +03:00
Laurent Pinchart
91d06ae2fc
libcamera: file: Use Flags<> class for open flags
...
Use the newly introduced Flags<> class to store a bitfield of
File::OpenMode in a type-safe way. The existing File::OpenMode enum is
renamed to File::OpenModeFlag to free the File::OpenMode for the Flags<>
type alias.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com >
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org >
2021-08-03 10:55:30 +03:00
Laurent Pinchart
49862904f6
libcamera: file: Use Flags<> class for map flags
...
Use the newly introduced Flags<> class to store a bitfield of
File::MapFlag in a type-safe way.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com >
Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se >
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org >
2021-08-03 10:55:26 +03:00
Kieran Bingham
b304bc013e
libcamera/base: Move File to base library
...
The File abstraction is a base helper and not part of the libcamera
API. Move it to to allow usage by users of the base library.
Reviewed-by: Hirokazu Honda <hiroh@chromium.org >
Reviewed-by: Paul Elder <paul.elder@ideasonboard.com >
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com >
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com >
2021-06-25 16:11:10 +01:00