122554020SJani Nikula============= 2ca00c2b9SJani NikulaDRM Internals 3ca00c2b9SJani Nikula============= 4ca00c2b9SJani Nikula 5ca00c2b9SJani NikulaThis chapter documents DRM internals relevant to driver authors and 6ca00c2b9SJani Nikuladevelopers working to add support for the latest features to existing 7ca00c2b9SJani Nikuladrivers. 8ca00c2b9SJani Nikula 9ca00c2b9SJani NikulaFirst, we go over some typical driver initialization requirements, like 10ca00c2b9SJani Nikulasetting up command buffers, creating an initial output configuration, 11ca00c2b9SJani Nikulaand initializing core services. Subsequent sections cover core internals 12ca00c2b9SJani Nikulain more detail, providing implementation notes and examples. 13ca00c2b9SJani Nikula 14ca00c2b9SJani NikulaThe DRM layer provides several services to graphics drivers, many of 15ca00c2b9SJani Nikulathem driven by the application interfaces it provides through libdrm, 16ca00c2b9SJani Nikulathe library that wraps most of the DRM ioctls. These include vblank 17ca00c2b9SJani Nikulaevent handling, memory management, output management, framebuffer 18ca00c2b9SJani Nikulamanagement, command submission & fencing, suspend/resume support, and 19ca00c2b9SJani NikulaDMA services. 20ca00c2b9SJani Nikula 21ca00c2b9SJani NikulaDriver Initialization 2222554020SJani Nikula===================== 23ca00c2b9SJani Nikula 24ca00c2b9SJani NikulaAt the core of every DRM driver is a :c:type:`struct drm_driver 25ca00c2b9SJani Nikula<drm_driver>` structure. Drivers typically statically initialize 26ca00c2b9SJani Nikulaa drm_driver structure, and then pass it to 27ca00c2b9SJani Nikula:c:func:`drm_dev_alloc()` to allocate a device instance. After the 28ca00c2b9SJani Nikuladevice instance is fully initialized it can be registered (which makes 29ca00c2b9SJani Nikulait accessible from userspace) using :c:func:`drm_dev_register()`. 30ca00c2b9SJani Nikula 31ca00c2b9SJani NikulaThe :c:type:`struct drm_driver <drm_driver>` structure 32ca00c2b9SJani Nikulacontains static information that describes the driver and features it 33ca00c2b9SJani Nikulasupports, and pointers to methods that the DRM core will call to 34ca00c2b9SJani Nikulaimplement the DRM API. We will first go through the :c:type:`struct 35ca00c2b9SJani Nikuladrm_driver <drm_driver>` static information fields, and will 36ca00c2b9SJani Nikulathen describe individual operations in details as they get used in later 37ca00c2b9SJani Nikulasections. 38ca00c2b9SJani Nikula 39ca00c2b9SJani NikulaDriver Information 4022554020SJani Nikula------------------ 41ca00c2b9SJani Nikula 42ca00c2b9SJani NikulaDriver Features 432fa91d15SJani Nikula~~~~~~~~~~~~~~~ 44ca00c2b9SJani Nikula 45ca00c2b9SJani NikulaDrivers inform the DRM core about their requirements and supported 46ca00c2b9SJani Nikulafeatures by setting appropriate flags in the driver_features field. 47ca00c2b9SJani NikulaSince those flags influence the DRM core behaviour since registration 48ca00c2b9SJani Nikulatime, most of them must be set to registering the :c:type:`struct 49ca00c2b9SJani Nikuladrm_driver <drm_driver>` instance. 50ca00c2b9SJani Nikula 51ca00c2b9SJani Nikulau32 driver_features; 52ca00c2b9SJani Nikula 53ca00c2b9SJani NikulaDRIVER_USE_AGP 54ca00c2b9SJani Nikula Driver uses AGP interface, the DRM core will manage AGP resources. 55ca00c2b9SJani Nikula 563cbf6a5dSDaniel VetterDRIVER_LEGACY 573cbf6a5dSDaniel Vetter Denote a legacy driver using shadow attach. Don't use. 583cbf6a5dSDaniel Vetter 593cbf6a5dSDaniel VetterDRIVER_KMS_LEGACY_CONTEXT 603cbf6a5dSDaniel Vetter Used only by nouveau for backwards compatibility with existing userspace. 613cbf6a5dSDaniel Vetter Don't use. 62ca00c2b9SJani Nikula 63ca00c2b9SJani NikulaDRIVER_PCI_DMA 64ca00c2b9SJani Nikula Driver is capable of PCI DMA, mapping of PCI DMA buffers to 65ca00c2b9SJani Nikula userspace will be enabled. Deprecated. 66ca00c2b9SJani Nikula 67ca00c2b9SJani NikulaDRIVER_SG 68ca00c2b9SJani Nikula Driver can perform scatter/gather DMA, allocation and mapping of 69ca00c2b9SJani Nikula scatter/gather buffers will be enabled. Deprecated. 70ca00c2b9SJani Nikula 71ca00c2b9SJani NikulaDRIVER_HAVE_DMA 72ca00c2b9SJani Nikula Driver supports DMA, the userspace DMA API will be supported. 73ca00c2b9SJani Nikula Deprecated. 74ca00c2b9SJani Nikula 75ca00c2b9SJani NikulaDRIVER_HAVE_IRQ; DRIVER_IRQ_SHARED 76ca00c2b9SJani Nikula DRIVER_HAVE_IRQ indicates whether the driver has an IRQ handler 77ca00c2b9SJani Nikula managed by the DRM Core. The core will support simple IRQ handler 78ca00c2b9SJani Nikula installation when the flag is set. The installation process is 79ca00c2b9SJani Nikula described in ?. 80ca00c2b9SJani Nikula 81ca00c2b9SJani Nikula DRIVER_IRQ_SHARED indicates whether the device & handler support 82ca00c2b9SJani Nikula shared IRQs (note that this is required of PCI drivers). 83ca00c2b9SJani Nikula 84ca00c2b9SJani NikulaDRIVER_GEM 85ca00c2b9SJani Nikula Driver use the GEM memory manager. 86ca00c2b9SJani Nikula 87ca00c2b9SJani NikulaDRIVER_MODESET 88ca00c2b9SJani Nikula Driver supports mode setting interfaces (KMS). 89ca00c2b9SJani Nikula 90ca00c2b9SJani NikulaDRIVER_PRIME 91ca00c2b9SJani Nikula Driver implements DRM PRIME buffer sharing. 92ca00c2b9SJani Nikula 93ca00c2b9SJani NikulaDRIVER_RENDER 94ca00c2b9SJani Nikula Driver supports dedicated render nodes. 95ca00c2b9SJani Nikula 96ca00c2b9SJani NikulaDRIVER_ATOMIC 97ca00c2b9SJani Nikula Driver supports atomic properties. In this case the driver must 98ca00c2b9SJani Nikula implement appropriate obj->atomic_get_property() vfuncs for any 99ca00c2b9SJani Nikula modeset objects with driver specific properties. 100ca00c2b9SJani Nikula 101ca00c2b9SJani NikulaMajor, Minor and Patchlevel 1022fa91d15SJani Nikula~~~~~~~~~~~~~~~~~~~~~~~~~~~ 103ca00c2b9SJani Nikula 104ca00c2b9SJani Nikulaint major; int minor; int patchlevel; 105ca00c2b9SJani NikulaThe DRM core identifies driver versions by a major, minor and patch 106ca00c2b9SJani Nikulalevel triplet. The information is printed to the kernel log at 107ca00c2b9SJani Nikulainitialization time and passed to userspace through the 108ca00c2b9SJani NikulaDRM_IOCTL_VERSION ioctl. 109ca00c2b9SJani Nikula 110ca00c2b9SJani NikulaThe major and minor numbers are also used to verify the requested driver 111ca00c2b9SJani NikulaAPI version passed to DRM_IOCTL_SET_VERSION. When the driver API 112ca00c2b9SJani Nikulachanges between minor versions, applications can call 113ca00c2b9SJani NikulaDRM_IOCTL_SET_VERSION to select a specific version of the API. If the 114ca00c2b9SJani Nikularequested major isn't equal to the driver major, or the requested minor 115ca00c2b9SJani Nikulais larger than the driver minor, the DRM_IOCTL_SET_VERSION call will 116ca00c2b9SJani Nikulareturn an error. Otherwise the driver's set_version() method will be 117ca00c2b9SJani Nikulacalled with the requested version. 118ca00c2b9SJani Nikula 119ca00c2b9SJani NikulaName, Description and Date 1202fa91d15SJani Nikula~~~~~~~~~~~~~~~~~~~~~~~~~~ 121ca00c2b9SJani Nikula 122ca00c2b9SJani Nikulachar \*name; char \*desc; char \*date; 123ca00c2b9SJani NikulaThe driver name is printed to the kernel log at initialization time, 124ca00c2b9SJani Nikulaused for IRQ registration and passed to userspace through 125ca00c2b9SJani NikulaDRM_IOCTL_VERSION. 126ca00c2b9SJani Nikula 127ca00c2b9SJani NikulaThe driver description is a purely informative string passed to 128ca00c2b9SJani Nikulauserspace through the DRM_IOCTL_VERSION ioctl and otherwise unused by 129ca00c2b9SJani Nikulathe kernel. 130ca00c2b9SJani Nikula 131ca00c2b9SJani NikulaThe driver date, formatted as YYYYMMDD, is meant to identify the date of 132ca00c2b9SJani Nikulathe latest modification to the driver. However, as most drivers fail to 133ca00c2b9SJani Nikulaupdate it, its value is mostly useless. The DRM core prints it to the 134ca00c2b9SJani Nikulakernel log at initialization time and passes it to userspace through the 135ca00c2b9SJani NikulaDRM_IOCTL_VERSION ioctl. 136ca00c2b9SJani Nikula 137ca00c2b9SJani NikulaDevice Instance and Driver Handling 13822554020SJani Nikula----------------------------------- 139ca00c2b9SJani Nikula 140ca00c2b9SJani Nikula.. kernel-doc:: drivers/gpu/drm/drm_drv.c 141ca00c2b9SJani Nikula :doc: driver instance overview 142ca00c2b9SJani Nikula 1436c4789edSDaniel Vetter.. kernel-doc:: include/drm/drm_drv.h 1446c4789edSDaniel Vetter :internal: 1456c4789edSDaniel Vetter 146*1ea35768SDaniel Vetter.. kernel-doc:: drivers/gpu/drm/drm_drv.c 147*1ea35768SDaniel Vetter :export: 148*1ea35768SDaniel Vetter 149ca00c2b9SJani NikulaDriver Load 15022554020SJani Nikula----------- 151ca00c2b9SJani Nikula 152ca00c2b9SJani NikulaIRQ Registration 1532fa91d15SJani Nikula~~~~~~~~~~~~~~~~ 154ca00c2b9SJani Nikula 155ca00c2b9SJani NikulaThe DRM core tries to facilitate IRQ handler registration and 156ca00c2b9SJani Nikulaunregistration by providing :c:func:`drm_irq_install()` and 157ca00c2b9SJani Nikula:c:func:`drm_irq_uninstall()` functions. Those functions only 158ca00c2b9SJani Nikulasupport a single interrupt per device, devices that use more than one 159ca00c2b9SJani NikulaIRQs need to be handled manually. 160ca00c2b9SJani Nikula 161ca00c2b9SJani NikulaManaged IRQ Registration 162ca00c2b9SJani Nikula'''''''''''''''''''''''' 163ca00c2b9SJani Nikula 164ca00c2b9SJani Nikula:c:func:`drm_irq_install()` starts by calling the irq_preinstall 165ca00c2b9SJani Nikuladriver operation. The operation is optional and must make sure that the 166ca00c2b9SJani Nikulainterrupt will not get fired by clearing all pending interrupt flags or 167ca00c2b9SJani Nikuladisabling the interrupt. 168ca00c2b9SJani Nikula 169ca00c2b9SJani NikulaThe passed-in IRQ will then be requested by a call to 170ca00c2b9SJani Nikula:c:func:`request_irq()`. If the DRIVER_IRQ_SHARED driver feature 171ca00c2b9SJani Nikulaflag is set, a shared (IRQF_SHARED) IRQ handler will be requested. 172ca00c2b9SJani Nikula 173ca00c2b9SJani NikulaThe IRQ handler function must be provided as the mandatory irq_handler 174ca00c2b9SJani Nikuladriver operation. It will get passed directly to 175ca00c2b9SJani Nikula:c:func:`request_irq()` and thus has the same prototype as all IRQ 176ca00c2b9SJani Nikulahandlers. It will get called with a pointer to the DRM device as the 177ca00c2b9SJani Nikulasecond argument. 178ca00c2b9SJani Nikula 179ca00c2b9SJani NikulaFinally the function calls the optional irq_postinstall driver 180ca00c2b9SJani Nikulaoperation. The operation usually enables interrupts (excluding the 181ca00c2b9SJani Nikulavblank interrupt, which is enabled separately), but drivers may choose 182ca00c2b9SJani Nikulato enable/disable interrupts at a different time. 183ca00c2b9SJani Nikula 184ca00c2b9SJani Nikula:c:func:`drm_irq_uninstall()` is similarly used to uninstall an 185ca00c2b9SJani NikulaIRQ handler. It starts by waking up all processes waiting on a vblank 186ca00c2b9SJani Nikulainterrupt to make sure they don't hang, and then calls the optional 187ca00c2b9SJani Nikulairq_uninstall driver operation. The operation must disable all hardware 188ca00c2b9SJani Nikulainterrupts. Finally the function frees the IRQ by calling 189ca00c2b9SJani Nikula:c:func:`free_irq()`. 190ca00c2b9SJani Nikula 191ca00c2b9SJani NikulaManual IRQ Registration 192ca00c2b9SJani Nikula''''''''''''''''''''''' 193ca00c2b9SJani Nikula 194ca00c2b9SJani NikulaDrivers that require multiple interrupt handlers can't use the managed 195ca00c2b9SJani NikulaIRQ registration functions. In that case IRQs must be registered and 196ca00c2b9SJani Nikulaunregistered manually (usually with the :c:func:`request_irq()` and 197a9eaa996SDaniel Vetter:c:func:`free_irq()` functions, or their :c:func:`devm_request_irq()` and 198a9eaa996SDaniel Vetter:c:func:`devm_free_irq()` equivalents). 199ca00c2b9SJani Nikula 200ca00c2b9SJani NikulaWhen manually registering IRQs, drivers must not set the 201ca00c2b9SJani NikulaDRIVER_HAVE_IRQ driver feature flag, and must not provide the 202ca00c2b9SJani Nikulairq_handler driver operation. They must set the :c:type:`struct 203ca00c2b9SJani Nikuladrm_device <drm_device>` irq_enabled field to 1 upon 204ca00c2b9SJani Nikularegistration of the IRQs, and clear it to 0 after unregistering the 205ca00c2b9SJani NikulaIRQs. 206ca00c2b9SJani Nikula 207ca00c2b9SJani NikulaMemory Manager Initialization 2082fa91d15SJani Nikula~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 209ca00c2b9SJani Nikula 210ca00c2b9SJani NikulaEvery DRM driver requires a memory manager which must be initialized at 211ca00c2b9SJani Nikulaload time. DRM currently contains two memory managers, the Translation 212ca00c2b9SJani NikulaTable Manager (TTM) and the Graphics Execution Manager (GEM). This 213ca00c2b9SJani Nikuladocument describes the use of the GEM memory manager only. See ? for 214ca00c2b9SJani Nikuladetails. 215ca00c2b9SJani Nikula 216ca00c2b9SJani NikulaMiscellaneous Device Configuration 2172fa91d15SJani Nikula~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 218ca00c2b9SJani Nikula 219ca00c2b9SJani NikulaAnother task that may be necessary for PCI devices during configuration 220ca00c2b9SJani Nikulais mapping the video BIOS. On many devices, the VBIOS describes device 221ca00c2b9SJani Nikulaconfiguration, LCD panel timings (if any), and contains flags indicating 222ca00c2b9SJani Nikuladevice state. Mapping the BIOS can be done using the pci_map_rom() 223ca00c2b9SJani Nikulacall, a convenience function that takes care of mapping the actual ROM, 224ca00c2b9SJani Nikulawhether it has been shadowed into memory (typically at address 0xc0000) 225ca00c2b9SJani Nikulaor exists on the PCI device in the ROM BAR. Note that after the ROM has 226ca00c2b9SJani Nikulabeen mapped and any necessary information has been extracted, it should 227ca00c2b9SJani Nikulabe unmapped; on many devices, the ROM address decoder is shared with 228ca00c2b9SJani Nikulaother BARs, so leaving it mapped could cause undesired behaviour like 229ca00c2b9SJani Nikulahangs or memory corruption. 230ca00c2b9SJani Nikula 231ca00c2b9SJani NikulaBus-specific Device Registration and PCI Support 23222554020SJani Nikula------------------------------------------------ 233ca00c2b9SJani Nikula 234ca00c2b9SJani NikulaA number of functions are provided to help with device registration. The 235ca00c2b9SJani Nikulafunctions deal with PCI and platform devices respectively and are only 236ca00c2b9SJani Nikulaprovided for historical reasons. These are all deprecated and shouldn't 237ca00c2b9SJani Nikulabe used in new drivers. Besides that there's a few helpers for pci 238ca00c2b9SJani Nikuladrivers. 239ca00c2b9SJani Nikula 240ca00c2b9SJani Nikula.. kernel-doc:: drivers/gpu/drm/drm_pci.c 241ca00c2b9SJani Nikula :export: 242ca00c2b9SJani Nikula 243ca00c2b9SJani NikulaOpen/Close, File Operations and IOCTLs 24422554020SJani Nikula====================================== 245ca00c2b9SJani Nikula 246ca00c2b9SJani NikulaFile Operations 24722554020SJani Nikula--------------- 248ca00c2b9SJani Nikula 2499acdac68SDaniel Vetter.. kernel-doc:: drivers/gpu/drm/drm_file.c 250ca00c2b9SJani Nikula :doc: file operations 251ca00c2b9SJani Nikula 252b93658f8SDaniel Vetter.. kernel-doc:: include/drm/drm_file.h 253b93658f8SDaniel Vetter :internal: 254b93658f8SDaniel Vetter 2559acdac68SDaniel Vetter.. kernel-doc:: drivers/gpu/drm/drm_file.c 256ca00c2b9SJani Nikula :export: 257ca00c2b9SJani Nikula 258ca00c2b9SJani NikulaIOCTLs 25922554020SJani Nikula------ 260ca00c2b9SJani Nikula 261ca00c2b9SJani Nikulastruct drm_ioctl_desc \*ioctls; int num_ioctls; 262ca00c2b9SJani Nikula Driver-specific ioctls descriptors table. 263ca00c2b9SJani Nikula 264ca00c2b9SJani NikulaDriver-specific ioctls numbers start at DRM_COMMAND_BASE. The ioctls 265ca00c2b9SJani Nikuladescriptors table is indexed by the ioctl number offset from the base 266ca00c2b9SJani Nikulavalue. Drivers can use the DRM_IOCTL_DEF_DRV() macro to initialize 267ca00c2b9SJani Nikulathe table entries. 268ca00c2b9SJani Nikula 269ca00c2b9SJani Nikula:: 270ca00c2b9SJani Nikula 271ca00c2b9SJani Nikula DRM_IOCTL_DEF_DRV(ioctl, func, flags) 272ca00c2b9SJani Nikula 273ca00c2b9SJani Nikula``ioctl`` is the ioctl name. Drivers must define the DRM_##ioctl and 274ca00c2b9SJani NikulaDRM_IOCTL_##ioctl macros to the ioctl number offset from 275ca00c2b9SJani NikulaDRM_COMMAND_BASE and the ioctl number respectively. The first macro is 276ca00c2b9SJani Nikulaprivate to the device while the second must be exposed to userspace in a 277ca00c2b9SJani Nikulapublic header. 278ca00c2b9SJani Nikula 279ca00c2b9SJani Nikula``func`` is a pointer to the ioctl handler function compatible with the 280ca00c2b9SJani Nikula``drm_ioctl_t`` type. 281ca00c2b9SJani Nikula 282ca00c2b9SJani Nikula:: 283ca00c2b9SJani Nikula 284ca00c2b9SJani Nikula typedef int drm_ioctl_t(struct drm_device *dev, void *data, 285ca00c2b9SJani Nikula struct drm_file *file_priv); 286ca00c2b9SJani Nikula 287ca00c2b9SJani Nikula``flags`` is a bitmask combination of the following values. It restricts 288ca00c2b9SJani Nikulahow the ioctl is allowed to be called. 289ca00c2b9SJani Nikula 290ca00c2b9SJani Nikula- DRM_AUTH - Only authenticated callers allowed 291ca00c2b9SJani Nikula 292ca00c2b9SJani Nikula- DRM_MASTER - The ioctl can only be called on the master file handle 293ca00c2b9SJani Nikula 294ca00c2b9SJani Nikula- DRM_ROOT_ONLY - Only callers with the SYSADMIN capability allowed 295ca00c2b9SJani Nikula 296ca00c2b9SJani Nikula- DRM_CONTROL_ALLOW - The ioctl can only be called on a control 297ca00c2b9SJani Nikula device 298ca00c2b9SJani Nikula 299ca00c2b9SJani Nikula- DRM_UNLOCKED - The ioctl handler will be called without locking the 300ca00c2b9SJani Nikula DRM global mutex. This is the enforced default for kms drivers (i.e. 301ca00c2b9SJani Nikula using the DRIVER_MODESET flag) and hence shouldn't be used any more 302ca00c2b9SJani Nikula for new drivers. 303ca00c2b9SJani Nikula 304ca00c2b9SJani Nikula.. kernel-doc:: drivers/gpu/drm/drm_ioctl.c 305ca00c2b9SJani Nikula :export: 306ca00c2b9SJani Nikula 307d8187177SRob Clark 308d8187177SRob ClarkMisc Utilities 309d8187177SRob Clark============== 310d8187177SRob Clark 311d8187177SRob ClarkPrinter 312d8187177SRob Clark------- 313d8187177SRob Clark 314d8187177SRob Clark.. kernel-doc:: include/drm/drm_print.h 315d8187177SRob Clark :doc: print 316d8187177SRob Clark 317d8187177SRob Clark.. kernel-doc:: include/drm/drm_print.h 318d8187177SRob Clark :internal: 319d8187177SRob Clark 3202d5e836dSDaniel Vetter.. kernel-doc:: drivers/gpu/drm/drm_print.c 321d8187177SRob Clark :export: 322d8187177SRob Clark 323d8187177SRob Clark 324ca00c2b9SJani NikulaLegacy Support Code 32522554020SJani Nikula=================== 326ca00c2b9SJani Nikula 327ca00c2b9SJani NikulaThe section very briefly covers some of the old legacy support code 328ca00c2b9SJani Nikulawhich is only used by old DRM drivers which have done a so-called 329ca00c2b9SJani Nikulashadow-attach to the underlying device instead of registering as a real 330ca00c2b9SJani Nikuladriver. This also includes some of the old generic buffer management and 331ca00c2b9SJani Nikulacommand submission code. Do not use any of this in new and modern 332ca00c2b9SJani Nikuladrivers. 333ca00c2b9SJani Nikula 334ca00c2b9SJani NikulaLegacy Suspend/Resume 33522554020SJani Nikula--------------------- 336ca00c2b9SJani Nikula 337ca00c2b9SJani NikulaThe DRM core provides some suspend/resume code, but drivers wanting full 338ca00c2b9SJani Nikulasuspend/resume support should provide save() and restore() functions. 339ca00c2b9SJani NikulaThese are called at suspend, hibernate, or resume time, and should 340ca00c2b9SJani Nikulaperform any state save or restore required by your device across suspend 341ca00c2b9SJani Nikulaor hibernate states. 342ca00c2b9SJani Nikula 343ca00c2b9SJani Nikulaint (\*suspend) (struct drm_device \*, pm_message_t state); int 344ca00c2b9SJani Nikula(\*resume) (struct drm_device \*); 345ca00c2b9SJani NikulaThose are legacy suspend and resume methods which *only* work with the 346ca00c2b9SJani Nikulalegacy shadow-attach driver registration functions. New driver should 347ca00c2b9SJani Nikulause the power management interface provided by their bus type (usually 348ca00c2b9SJani Nikulathrough the :c:type:`struct device_driver <device_driver>` 349ca00c2b9SJani Nikuladev_pm_ops) and set these methods to NULL. 350ca00c2b9SJani Nikula 351ca00c2b9SJani NikulaLegacy DMA Services 35222554020SJani Nikula------------------- 353ca00c2b9SJani Nikula 354ca00c2b9SJani NikulaThis should cover how DMA mapping etc. is supported by the core. These 355ca00c2b9SJani Nikulafunctions are deprecated and should not be used. 356