platform/core/uifw/libtbm.git
3 years agotbm_module: add tbm_module_bo_unmap and use it 20/260020/1
SooChan Lim [Thu, 17 Jun 2021 08:27:33 +0000 (17:27 +0900)]
tbm_module: add tbm_module_bo_unmap and use it

The tbm_module_bo_unmap calls it's backend function

Change-Id: I4dbd8164bf1cbd7d67af0e22ce40d46be24dabd1

3 years agotbm_module: add tbm_module_bo_map and use it 19/260019/1
SooChan Lim [Thu, 17 Jun 2021 08:18:14 +0000 (17:18 +0900)]
tbm_module: add tbm_module_bo_map and use it

The tbm_module_bo_map calls it's backend function

Change-Id: I73cd41c9fe283a3e8d406a1a80d5468a494e98be

3 years agotbm_module: add tbm_module_bo_get_bo_handle and use it 18/260018/1
SooChan Lim [Thu, 17 Jun 2021 08:08:48 +0000 (17:08 +0900)]
tbm_module: add tbm_module_bo_get_bo_handle and use it

The tbm_module_bo_get_bo_handle calls it's backend function

Change-Id: I14f12650031bc1ca250de953724e8ac9f91e7664

3 years agotbm_module: add tbm_module_bo_get_memory_types and use it 17/260017/1
SooChan Lim [Thu, 17 Jun 2021 07:45:54 +0000 (16:45 +0900)]
tbm_module: add tbm_module_bo_get_memory_types and use it

The tbm_module_bo_get_memory_types calls it's backend function

Change-Id: I1d56ab9485bc1cccf089c65cd66da87fae288823

3 years agotbm_module: add tbm_module_bo_get_size and use it 16/260016/1
SooChan Lim [Thu, 17 Jun 2021 07:30:08 +0000 (16:30 +0900)]
tbm_module: add tbm_module_bo_get_size and use it

The tbm_module_bo_get_size calls it's backend function.

Change-Id: I8b06b99e565b673de3a192537658b1bb0e63e1dd

3 years agotbm_module: add tbm_module_bo_free and use it 15/260015/1
SooChan Lim [Thu, 17 Jun 2021 07:07:21 +0000 (16:07 +0900)]
tbm_module: add tbm_module_bo_free and use it

The tbm_module_bo_free calls it's backend function.

Change-Id: Ic0aa305f742ef543119d607061c8abe59cf1bae9

3 years agoPackage version up to 4.1.3 65/259965/1 submit/tizen/20210617.053259 submit/tizen/20210621.000815
SooChan Lim [Thu, 17 Jun 2021 04:56:58 +0000 (13:56 +0900)]
Package version up to 4.1.3

Change-Id: Iff89a3f9519d316f2ba49598ba7c47481082b66e

3 years agotbm_surface_internal: donot set error type 41/259941/1
SooChan Lim [Thu, 17 Jun 2021 01:34:36 +0000 (10:34 +0900)]
tbm_surface_internal: donot set error type

the error type should be set by hal backend.

Change-Id: I4a7c47d8a091c01c124d09072462ae18a317ea8b

3 years agotbm_surface_internal: remove dead code 40/259940/1
SooChan Lim [Thu, 17 Jun 2021 01:18:30 +0000 (10:18 +0900)]
tbm_surface_internal: remove dead code

Change-Id: I540255281d74ade6a96c0e98ed50f4ffc6c5eeeb

3 years agotbm_module: fix the wrong condition 39/259939/1
SooChan Lim [Thu, 17 Jun 2021 01:02:08 +0000 (10:02 +0900)]
tbm_module: fix the wrong condition

A fd has to be checked if it is less than 0.

Change-Id: Ia71d5208060e4d1e6e6965c3f3848e0d77aaea6c

3 years agotbm_bufmgr: make a reset function for initializing module_data 38/259938/1
SooChan Lim [Thu, 17 Jun 2021 01:00:44 +0000 (10:00 +0900)]
tbm_bufmgr: make a reset function for initializing module_data

This static function will be deleted after refactoring tbm_module.

Change-Id: Icb63be6362f3b03f1eb99d2444f569f8b75cc70b

3 years agotbm_surface_internal: check the memory validation at macro 37/259937/1
SooChan Lim [Thu, 17 Jun 2021 00:48:11 +0000 (09:48 +0900)]
tbm_surface_internal: check the memory validation at macro

checkt the validataion of the error pointer at TBM_SURFACE_RETURN_VAL_SET_ERR_IF_FAIL

Change-Id: Idd6815577e1e03d0bfc0ad1e234e348e18b7055f

3 years agotbm_bufmgr: add tbm_bufmgr_internal_import_bo_with_fd and use it 04/259904/1
SooChan Lim [Wed, 16 Jun 2021 08:20:54 +0000 (17:20 +0900)]
tbm_bufmgr: add tbm_bufmgr_internal_import_bo_with_fd and use it

The tbm_bufmgr generates tbm_bo and manages them

Change-Id: Ie292badda463f17a7e0eba0b4320c9ea537ab7c1

3 years agotbm_bufmgr: add tbm_bufmgr_internal_import_bo_with_key and use it 03/259903/1
SooChan Lim [Wed, 16 Jun 2021 07:55:13 +0000 (16:55 +0900)]
tbm_bufmgr: add tbm_bufmgr_internal_import_bo_with_key and use it

The tbm_bufmgr generates tbm_bo and manages them

Change-Id: Iac149b45c70a38eefc887a11770dde0d61faeeb7

3 years agotbm_bufmgr: add tbm_bufmgr_internal_alloc_bo and use it 02/259902/1
SooChan Lim [Wed, 16 Jun 2021 07:42:24 +0000 (16:42 +0900)]
tbm_bufmgr: add tbm_bufmgr_internal_alloc_bo and use it

The tbm_bufmgr generates tbm_bo and manages them.

Change-Id: I2dae9758aba658c28c26ba595a049edc45f914c8

3 years agotbm_bufmgr: change tbm_bo_alloc_with_bo_data name 01/259901/1
SooChan Lim [Wed, 16 Jun 2021 06:00:00 +0000 (15:00 +0900)]
tbm_bufmgr: change tbm_bo_alloc_with_bo_data name

change tbm_bo_alloc_with_bo_data into tbm_bufmgr_internal_alloc_bo_with_bo_data
and move this function to tbm_bufmgr.c

Change-Id: I7266e1630043d9ee64ea228070b6f78940d4acc0

3 years agotbm_bufmgr: change tbm_bo_alloc_with_format name 00/259900/1
SooChan Lim [Wed, 16 Jun 2021 05:40:40 +0000 (14:40 +0900)]
tbm_bufmgr: change tbm_bo_alloc_with_format name

change tbm_bo_alloc_with_format into tbm_bufmgr_internal_alloc_bo_with_format
and move this function to tbm_bufmgr.c

Change-Id: I1827f2ee05534ad7a56221b4c704a33dc965c432

3 years agotbm_bo: remove error log. 99/259899/1
SooChan Lim [Wed, 16 Jun 2021 05:17:50 +0000 (14:17 +0900)]
tbm_bo: remove error log.

Change-Id: Id8928e5abbfea8873e55f2e79e1f3b5059f2dc9f

3 years agotbm_bufmgr: add tbm_bufmgr_internal_find_bo 98/259898/1
SooChan Lim [Wed, 16 Jun 2021 03:14:02 +0000 (12:14 +0900)]
tbm_bufmgr: add tbm_bufmgr_internal_find_bo

The tbm_bufmgr_internal_find_bo find the bo which has
the same bo_data in the bufmgr->bo_list.

Change-Id: I6fe4cda6bac1714a8c9d69fb938a179f09cc701a

3 years agotbm_module: make tbm_module_bufmgr_import_key 97/259897/1
SooChan Lim [Tue, 15 Jun 2021 11:56:54 +0000 (20:56 +0900)]
tbm_module: make tbm_module_bufmgr_import_key

encapsulate the bufmgr_import_key with this function.

Change-Id: I45c098c07caa00038e1ec983dd11b535bb030f0d

3 years agotbm_module: make tbm_module_bufmgr_import_fd 96/259896/1
SooChan Lim [Tue, 15 Jun 2021 11:42:35 +0000 (20:42 +0900)]
tbm_module: make tbm_module_bufmgr_import_fd

encapsulate the bufmgr_import_fd with this function.

Change-Id: I8a5ed58ba688123875e7d26a1bb0545a7004d54d

3 years agotbm_module: make tbm_module_bufmgr_get_plane_data 95/259895/1
SooChan Lim [Tue, 15 Jun 2021 08:46:19 +0000 (17:46 +0900)]
tbm_module: make tbm_module_bufmgr_get_plane_data

encapsulate the bufmgr_get_plane_data with this function.

Change-Id: I8eb465b3a72e1831c0e46ca14e020fdc4af5e971

3 years agotbm_module: check coverage with the TBM_MODULE_TYPE_HAL_TBM 94/259894/1
SooChan Lim [Tue, 15 Jun 2021 05:42:31 +0000 (14:42 +0900)]
tbm_module: check coverage with the TBM_MODULE_TYPE_HAL_TBM

We do not check coverage with old module type.

Change-Id: If62e1a813a5117f0d3fcd0e60d84f67334b1e40c

3 years agotbm_module: make tbm_module_bufmgr_get_supported_format 93/259893/1
SooChan Lim [Tue, 15 Jun 2021 05:39:00 +0000 (14:39 +0900)]
tbm_module: make tbm_module_bufmgr_get_supported_format

encapsulate the bufmgr_get_supported_format with this function.

Change-Id: Ia816a505b2a0bfa7cd01997c44f0b1317696761a

3 years agotbm_module: TBM_MODULE_TYPE_BUFMGR_BACKEND is deprecated after Tizen 6.5 92/259892/1
SooChan Lim [Tue, 15 Jun 2021 05:20:36 +0000 (14:20 +0900)]
tbm_module: TBM_MODULE_TYPE_BUFMGR_BACKEND is deprecated after Tizen 6.5

Change-Id: I84d24e9b3de06de9f72cf1f85a3e40354b64d435

3 years agotbm_module: make tbm_module_bufmgr_bind_native_display 91/259891/1
SooChan Lim [Tue, 15 Jun 2021 05:19:37 +0000 (14:19 +0900)]
tbm_module: make tbm_module_bufmgr_bind_native_display

encapsulate the bufmgr_bind_native_display with this function.

Change-Id: I777a9ff365b9211eaacb7a350623c8974cd77324

3 years agotbm_bo: remove tbm_bo_alloc_with_surface 90/259890/1
SooChan Lim [Tue, 15 Jun 2021 04:38:08 +0000 (13:38 +0900)]
tbm_bo: remove tbm_bo_alloc_with_surface

The tbm_bo_alloc_with_surface does not use anymore.
The bufmgr->backend will be deprecated.

Change-Id: I032df2de270e2fd4bbe7f5829bdede962213d8ab

3 years agotbm_surface_internal: remove direct alls of backend functions 89/259889/1
SooChan Lim [Tue, 15 Jun 2021 03:25:35 +0000 (12:25 +0900)]
tbm_surface_internal: remove direct alls of backend functions

The tbm_bo_alloc_with_format calls tbm_module_bo_alloc_with_format.
The tbm_module_bo_alloc_with_format calls the backend functions.

Change-Id: Ic5cac77257e95e567367b6f16c395c55dd22beba

3 years agotbm_bo: remove tbm_bo_alloc_with_tiled_format 88/259888/1
SooChan Lim [Tue, 15 Jun 2021 03:11:43 +0000 (12:11 +0900)]
tbm_bo: remove tbm_bo_alloc_with_tiled_format

This function is internal function and it is not used anymore.
The bufmgr_func->bufmgr_alloc_bo_with_tiled_format backend func will
be deprecated.

Change-Id: Id933ac57cdbf337734d430570399725f7a218dac

3 years agotbm_module: check the bufmgr_func symbol at tbm_module_bufmgr_get_capabilities 87/259887/1
SooChan Lim [Tue, 15 Jun 2021 04:20:42 +0000 (13:20 +0900)]
tbm_module: check the bufmgr_func symbol at tbm_module_bufmgr_get_capabilities

This avoids a crash when the bufmgr_funcs does not have a symbol.

Change-Id: I27109d06403d974629badf17bc6ed8eb49cfd6cb

3 years agotbm_module: make tbm_module_bufmgr_bo_alloc_with_format function 86/259886/1
SooChan Lim [Mon, 14 Jun 2021 08:56:51 +0000 (17:56 +0900)]
tbm_module: make tbm_module_bufmgr_bo_alloc_with_format function

encapsulate the bufmgr_bo_alloce_with_format with this function.

Change-Id: Ic68228a4204aaec28c4887bf9fd87194fd3e1937

3 years agotbm_module: get the error type at tbm_module_bufmgr_get_capabilities 85/259885/1
SooChan Lim [Fri, 11 Jun 2021 08:10:36 +0000 (17:10 +0900)]
tbm_module: get the error type at tbm_module_bufmgr_get_capabilities

return the error type which is returned by
tbm_module_bufmgr_get_capabilities

Change-Id: I7199e8e44ad802c1e743439321f1c2b5ac965739

3 years agotbm_module: make tbm_module_bufmgr_bo_alloc function 84/259884/1
SooChan Lim [Fri, 11 Jun 2021 07:53:55 +0000 (16:53 +0900)]
tbm_module: make tbm_module_bufmgr_bo_alloc function

encapsulate the bufmgr_bo_allocation with this function.

Change-Id: I28f3d6196950ca3a7e41757b63f8da64fc45a237

3 years agotbm_log: add the condition check macro with error 83/259883/1
SooChan Lim [Fri, 11 Jun 2021 08:06:15 +0000 (17:06 +0900)]
tbm_log: add the condition check macro with error

Change-Id: I064a9d7588a4d8ec0f02fa5da770b5c12c3bbcb6

3 years agotc: fix the prefix of the definition in tc_tbm.h 82/259882/1
SooChan Lim [Fri, 11 Jun 2021 07:27:25 +0000 (16:27 +0900)]
tc: fix the prefix of the definition in tc_tbm.h

Change-Id: If82a337d08ddc8a632a40679e7feaa13f8cf4a7a

3 years agotbm_bo: initialize the bo2 26/259826/1
SooChan Lim [Tue, 15 Jun 2021 08:53:18 +0000 (17:53 +0900)]
tbm_bo: initialize the bo2

Change-Id: I56c25746dabf86426ab632bcbfc8b6a6674da8d8

3 years agoPackage version up to 4.1.2 10/259710/2 submit/tizen/20210611.072439 submit/tizen/20210621.000827
SooChan Lim [Fri, 11 Jun 2021 06:36:05 +0000 (15:36 +0900)]
Package version up to 4.1.2

Change-Id: If75f028c54562ee417cdbe93440fb4cf03ba3906

3 years agotc: skip the test case when it does not have hal-tbm module 09/259709/2
SooChan Lim [Fri, 11 Jun 2021 06:34:42 +0000 (15:34 +0900)]
tc: skip the test case when it does not have hal-tbm module

Change-Id: I989c46b00750fc4b6d4a683dec44f6a015cea3df

3 years agotc: fix the macros for logging. 08/259708/2
SooChan Lim [Fri, 11 Jun 2021 06:33:43 +0000 (15:33 +0900)]
tc: fix the macros for logging.

fix the build break when it uses the log macro of logging

Change-Id: I6dff92297fcf0de224c32477df163b90d604353d

3 years agotbm_backend: fix the handle casting. 07/259707/2
SooChan Lim [Fri, 11 Jun 2021 06:32:28 +0000 (15:32 +0900)]
tbm_backend: fix the handle casting.

use tbm_modlue instead of tbm_bufmgr in libtbm because of refactoring of tbm_module.

Change-Id: I600299e09eef8facbbc9b7d4c5dbfd10bc70f540

3 years agotbm_module: remove bufmgr variable at tbm_module 06/259706/1
SooChan Lim [Fri, 11 Jun 2021 00:45:40 +0000 (09:45 +0900)]
tbm_module: remove bufmgr variable at tbm_module

The tbm_modlue does not have a dependency of tbm_bufmgr anymore.
Remove all tbm_bufmgr variables at tbm_module.

Change-Id: Ia8be69be53aaaac2985e820b368d265fa32f7149

3 years agotbm_bufmgr: move copy functions for module information to tbm_bufmgr 05/259705/1
SooChan Lim [Thu, 10 Jun 2021 23:56:31 +0000 (08:56 +0900)]
tbm_bufmgr: move copy functions for module information to tbm_bufmgr

The copy function for module information is moved from tbm_module to
tbm_bufmgr.

Change-Id: I99d0910042020839ce7efd728a5cb7127bd9f6f8

3 years agotbm_bufmgr: remove the included header file. 04/259704/1
SooChan Lim [Thu, 10 Jun 2021 06:49:47 +0000 (15:49 +0900)]
tbm_bufmgr: remove the included header file.

Change-Id: I9e6a5f79785f3101c0ef8170cd7a17ab52ca3f80

3 years agotbm_bufmgr: use tbm_module_bufmgr_get_capabilities 03/259703/1
SooChan Lim [Thu, 10 Jun 2021 06:47:23 +0000 (15:47 +0900)]
tbm_bufmgr: use tbm_module_bufmgr_get_capabilities

Use tbm_module_bufmgr_get_capabilities and
remove the code for getting capabilities at tbm_module.c

Change-Id: Iff76fa966f202a1a28e2a518733ba7901e43b490

3 years agotbm_module : add tbm_module_bufmgr_get_capabilities 02/259702/1
SooChan Lim [Thu, 10 Jun 2021 06:42:04 +0000 (15:42 +0900)]
tbm_module : add tbm_module_bufmgr_get_capabilities

This function returns the capabilities of the bufmgr module.

Change-Id: I9279fe2b025e46526931e0c063993723410ce61e

3 years agotbm_module: change if-statement into switch-case 01/259701/1
SooChan Lim [Thu, 10 Jun 2021 06:37:05 +0000 (15:37 +0900)]
tbm_module: change if-statement into switch-case

Change-Id: Ibba1869f6851bbc6a5a1d4074752c50b46ab7f46

3 years agotbm_module: use module instead of bufmgr 00/259700/1
SooChan Lim [Thu, 10 Jun 2021 06:22:28 +0000 (15:22 +0900)]
tbm_module: use module instead of bufmgr

set the information to tbm_module and
copy the information of tbm_module to bufmgr.
During the refactoring, the module infomation
in the bufmgr will be removed.

Change-Id: I94c9c121acf6af5bd8dea6377dd71fb29ee31eb6

3 years agotbm_bufmgr: use tbm_module_load/unload functions 99/259699/1
SooChan Lim [Thu, 10 Jun 2021 02:04:13 +0000 (11:04 +0900)]
tbm_bufmgr: use tbm_module_load/unload functions

Use tbm_module_load/unload functions and
remove the useless codes.

Change-Id: I1f239b514632a639c20874c1bdd4db2a397a9b4d

3 years agotbm_module: migrate the module funtions from tbm_bufmgr.c 98/259698/1
SooChan Lim [Thu, 10 Jun 2021 01:50:39 +0000 (10:50 +0900)]
tbm_module: migrate the module funtions from tbm_bufmgr.c

Copy the module functions in tbm_bufmgr.c to tbm_module.c

Change-Id: I7a5e18a82064a78a6239e8623e2431fee39dd08c

3 years agotbm_module: add tbm_module.c file 97/259697/1
SooChan Lim [Thu, 10 Jun 2021 01:25:26 +0000 (10:25 +0900)]
tbm_module: add tbm_module.c file

Change-Id: I5e8d4d9454f453d66381dacba1905817e04db245

3 years agotbm_bufmgr: define tbm_module structure. 96/259696/1
SooChan Lim [Thu, 10 Jun 2021 01:21:13 +0000 (10:21 +0900)]
tbm_bufmgr: define tbm_module structure.

The tbm_module manages the backend modules of tbm.
1. manage the backend types.
2. manage the backend resources.
2. control the backend functions.

Change-Id: I4c59c10b291acce91b98fe6013398b0c501011c2

3 years agoPackage version up to 4.1.1 70/259570/1 accepted/tizen/unified/20210611.013538 submit/tizen/20210610.005840 submit/tizen/20210621.000838
SooChan Lim [Thu, 10 Jun 2021 00:53:13 +0000 (09:53 +0900)]
Package version up to 4.1.1

Change-Id: Ia0b360300f1ae0734a87dfacc7759656277058ff

3 years agotbm_bo: add get_from_hal_surface flag at tbm_bo 69/259569/1
SooChan Lim [Thu, 10 Jun 2021 00:36:08 +0000 (09:36 +0900)]
tbm_bo: add get_from_hal_surface flag at tbm_bo

The bo_data has to be freed at hal backend when
the get_from_hal_surface flag at tbm_bo is set.
Otherwise, the bo_data is freed at libtbm.
hal_tbm_surface has to deal with the life-cycle
of the hal_tbm_bo created by hal_tbm_surface.

Change-Id: I9342e5990796543bf6cf4a366fce6753a279f1e2
Signed-off-by: SooChan Lim <sc1.lim@samsung.com>
3 years agoPackage version up to 4.1.0 38/258938/1 submit/tizen/20210531.033615 submit/tizen/20210602.040040 submit/tizen/20210603.042328 submit/tizen/20210608.000531 submit/tizen/20210608.232051
SooChan Lim [Fri, 28 May 2021 06:10:33 +0000 (15:10 +0900)]
Package version up to 4.1.0

Change-Id: Ibbeb5b4679f4d691e2ff127a4f7bc97864d44db4

3 years agotbm_bo: check the bo which has the same bo_data 75/258175/1
SooChan Lim [Tue, 11 May 2021 23:42:01 +0000 (08:42 +0900)]
tbm_bo: check the bo which has the same bo_data

There is just one bo with a bo_data, so increase the
reference count when it has the same bo_data.

Change-Id: I6258a6a8bf1f8a268619c70278f7b0d57a20b9ac

3 years agotbm_surface_internal: tbm_surface_internal_import 74/258174/1
SooChan Lim [Tue, 11 May 2021 23:40:45 +0000 (08:40 +0900)]
tbm_surface_internal: tbm_surface_internal_import

It returns tbm_surface_h from buffer_data.

Change-Id: Ib7f91c092d0c73cc9b707ad6ad3d8262d365b4cd

3 years agotbm_surface_internal: implement tbm_surface_internal_export 73/258173/1
SooChan Lim [Tue, 11 May 2021 23:39:07 +0000 (08:39 +0900)]
tbm_surface_internal: implement tbm_surface_internal_export

It returns a buffer_data.

Change-Id: I4cb6cdfd86815abe478429e5cfb792b9b9d66594

3 years agotbm_surface_internal: add some error log macros 72/258172/1
SooChan Lim [Tue, 11 May 2021 23:37:40 +0000 (08:37 +0900)]
tbm_surface_internal: add some error log macros

this macros deals with the tbm_error types when a condition is failed.

Change-Id: Ie458e7b84b3d39565a5b535dac7beac111330e51

3 years agotc: add tcs for tbm_surface_internal_export/import 71/258171/1
SooChan Lim [Mon, 10 May 2021 12:50:14 +0000 (21:50 +0900)]
tc: add tcs for tbm_surface_internal_export/import

Change-Id: Id65e71408a5a165db99d693325f118c2d22c54b0

3 years agotbm_bo: free hal_tbm_bo when it is allocated by tbm_bo_alloc 42/257742/6 submit/tizen/20210608.001159
SooChan Lim [Fri, 30 Apr 2021 07:03:46 +0000 (16:03 +0900)]
tbm_bo: free hal_tbm_bo when it is allocated by tbm_bo_alloc

The hal_tbm_do which is allocated by tbm_bo_alloc_with_tbm_backend_data
is not freed at this _tbm_bo_free. The hal_tbm_bo from hal_tbm_surface
will be and should be freed at the hal-tbm-api backend module.

Change-Id: Ie10ecc370d1365a2c4a1067d3295d3fb632d7a0d

3 years agoallocate the tbm_surface when it has hal_tbm. 41/257741/5 submit/tizen/20210608.001246
SooChan Lim [Fri, 30 Apr 2021 04:35:43 +0000 (13:35 +0900)]
allocate the tbm_surface when it has hal_tbm.

When libtbm uses hal-tbm-api, it creates a tbm_surface_h with a new
hal_tbm_surface.

Change-Id: Ic3aeb3d0d3b2b1a11b02b8f61ca57858a57ddbc9

3 years agoadd tbm_bo_alloc_with_bo_data 40/257740/1 submit/tizen/20210608.001222
SooChan Lim [Fri, 30 Apr 2021 04:33:54 +0000 (13:33 +0900)]
add tbm_bo_alloc_with_bo_data

The tbm_bo_alloc_with_bo_data allocate tbm_bo with tbm_backend_bo_data.

Change-Id: I2980170d99e907e64c263468ade10be8bf40fe17

3 years agotbm_surface_internal: set an error when the refcnt of a surface is less than 0 39/257739/1
SooChan Lim [Thu, 29 Apr 2021 07:49:23 +0000 (16:49 +0900)]
tbm_surface_internal: set an error when the refcnt of a surface is less than 0

Only at TW3, we can watch that the refcnt of a surface is less than 0
when we run tbm-haltests all.

Change-Id: I614c48c412783bbbe7a21cca905da3440e7057f0

3 years agotbm_surface_internal: make an internal function for creating a surface 38/257738/1
SooChan Lim [Thu, 29 Apr 2021 07:32:24 +0000 (16:32 +0900)]
tbm_surface_internal: make an internal function for creating a surface

refoctor the creation of a surface.

Change-Id: I4f798a361791b9f2f354c44cae6e92a21c88568e

3 years agoadd the definitions of export/import surface 40/257540/1 submit/tizen/20210608.000609
SooChan Lim [Tue, 27 Apr 2021 10:16:56 +0000 (19:16 +0900)]
add the definitions of export/import surface

add tbm_surface_buffer_data and define two surface_internal api below
 - tbm_surface_internal_export
 - tbm_surface_internal_import

Change-Id: Ib098d8799e8f61aa20c1ee71af4ffa6b0a27b182

3 years agofix the memory allocation failed. 81/255581/1 accepted/tizen/unified/20210324.124652 submit/tizen/20210319.090109 submit/tizen/20210319.090617 submit/tizen/20210323.100158
SooChan Lim [Fri, 19 Mar 2021 08:52:57 +0000 (17:52 +0900)]
fix the memory allocation failed.

libtbm must calls tbm_bo_alloc function when tbm_bo_alloc_with_format is not supported at the backend module.

Change-Id: Ie2c3e161b278b88c724d2be7023399895574298b

3 years agoPackage version up to 4.0.2 71/255471/1 submit/tizen/20210319.034626
SooChan Lim [Fri, 19 Mar 2021 01:32:17 +0000 (10:32 +0900)]
Package version up to 4.0.2

Change-Id: I668aba67c6990509578569b13403e12ee24d4182

3 years agotbm_bo : use hal_tbm_bufmgr_alloc_bo_with_format instead of hal_tbm_bufmgr_alloc_bo_w... 70/255470/1
SooChan Lim [Fri, 19 Mar 2021 01:27:13 +0000 (10:27 +0900)]
tbm_bo : use hal_tbm_bufmgr_alloc_bo_with_format instead of hal_tbm_bufmgr_alloc_bo_with_tiled_format

At hal_tbm, the backend consider if this tbm_bo is the tiled memory or not with hal_tbm_bo_memory_type.
Therefore, remove the use of hal_tbm_bufmgr_alloc_bo_with_tiled_format api. This api is deprecated at hal tbm.

Change-Id: I86a7561845312a0a5fccfddf9fce9ca39593a50c

3 years agohaltests: modify Makefile.am in order to support out of source build 95/255095/2
Jongmin Lee [Fri, 12 Mar 2021 03:45:44 +0000 (12:45 +0900)]
haltests: modify Makefile.am in order to support out of source build

Change-Id: I432235975f7c232f22eebbb89666431681dc8e6c

3 years agoPackage version up to 4.0.1 25/255025/1 submit/tizen/20210316.103642
Junkyeong Kim [Thu, 11 Mar 2021 08:49:18 +0000 (17:49 +0900)]
Package version up to 4.0.1

Change-Id: I4d1573c2f1d12d8a41c46bd2156424357b020100
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
3 years agoTdm_bo: Add null checking before use 23/255023/1
Junkyeong Kim [Thu, 11 Mar 2021 08:42:42 +0000 (17:42 +0900)]
Tdm_bo: Add null checking before use

Change-Id: I1b780b2eaeaac3cbf316156475a217f0628bef26
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
3 years agochange bin file position to /usr/bin/hal 77/254077/2
Junkyeong Kim [Tue, 23 Feb 2021 06:59:17 +0000 (15:59 +0900)]
change bin file position to /usr/bin/hal

Change-Id: Iec5ed001b0d78b4c17c962902b87192941998b07
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
3 years agotbm_surface_internal: check bufmgr init success before list init 80/254380/2
Junkyeong Kim [Tue, 2 Mar 2021 01:15:27 +0000 (10:15 +0900)]
tbm_surface_internal: check bufmgr init success before list init

Change-Id: I4b18a5b8375146d7518665d871585d8b8613027a
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
3 years agoPackage version up to 4.0.0 87/253987/2 accepted/tizen/unified/20210302.131108 submit/tizen/20210222.081804 submit/tizen/20210225.073439 submit/tizen/20210302.014712
SooChan Lim [Mon, 22 Feb 2021 03:53:43 +0000 (12:53 +0900)]
Package version up to 4.0.0

libtbm uses hal-api-tbm from v4.0.0 at Tizen 6.5

Change-Id: I0605930ed9bdd10371266a588dfaf0df69a13e74

3 years agoadd surface destroy callback add/remove api 48/253948/4
Junkyeong Kim [Sat, 20 Feb 2021 08:36:10 +0000 (17:36 +0900)]
add surface destroy callback add/remove api

Change-Id: I1e94f5e33599f074f423f3ad81ad2964aeb5c56d
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
3 years agohal: deal with auth drm_fd 84/253984/2
SooChan Lim [Tue, 16 Feb 2021 10:41:25 +0000 (19:41 +0900)]
hal: deal with auth drm_fd

tbm backend must have the authenticated drm_fd when it has a drm_device.
If master_fd set from libtdm exists, libtbm sets the authencated drm_fd to the backend.
If there is no master_fd, libtbm get the authenticated drm_fd from the process(display server)
which has a master fd.

Change-Id: I0111976a26dc1f26191439517e5d8869a8955a36
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
3 years agotbm_bo: do not print error if return value is NOT_SUPPORTED 83/253983/2
Junkyeong Kim [Mon, 8 Feb 2021 09:52:37 +0000 (18:52 +0900)]
tbm_bo: do not print error if return value is NOT_SUPPORTED

Change-Id: Iaf4aaab751d09c2a3aa1da873fc113a8fa80e2f9
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
3 years agoNOT_SUPPORTED return ture at lock/unlock 82/253982/2
SooChan Lim [Sun, 7 Feb 2021 06:47:03 +0000 (15:47 +0900)]
NOT_SUPPORTED return ture at lock/unlock

Change-Id: I64abc4f9c942d10d0830f2ca647276a02f54b0f3

3 years agotc_tbm_backend: do not check symbol if using hal-tbm 81/253981/2
Junkyeong Kim [Sun, 7 Feb 2021 06:27:41 +0000 (15:27 +0900)]
tc_tbm_backend: do not check symbol if using hal-tbm

Change-Id: I9b876de02b326a59a74298df92332b08205d93ce
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
3 years agoadd return value 80/253980/2
SooChan Lim [Sun, 7 Feb 2021 06:15:48 +0000 (15:15 +0900)]
add return value

Change-Id: I17763b2c40ba3914231ea5135cfad57707a4d3d9

3 years agotbm_bo: do not use error log parameter 79/253979/2
Junkyeong Kim [Sun, 7 Feb 2021 06:00:00 +0000 (15:00 +0900)]
tbm_bo: do not use error log parameter

Change-Id: I2884953db2effa50dba896973c7110523944e832
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
3 years agoadapt hal-api-tbm 78/253978/2
Junkyeong Kim [Thu, 4 Feb 2021 04:51:27 +0000 (13:51 +0900)]
adapt hal-api-tbm

libtbm uses hal-api-tbm from Tizen 6.5.
Therefore, libtbm links libhal-api-tbm library and libtbm work with
hal-api-tbm when the hal-backend-tbm backend library at /hal/lib directory.
If not, libtbm works with the legacy tbm backend so file at /usr/lib/bufmgr
directory.

Change-Id: I6428b3cddf8914f38c4b2ca55b5f731440846e2f
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
3 years agoPackage version up to 3.3.16 46/252246/1 accepted/tizen/unified/20210127.144834 submit/tizen/20210126.060057
Changyeon Lee [Tue, 26 Jan 2021 04:45:16 +0000 (13:45 +0900)]
Package version up to 3.3.16

Change-Id: Ieb1219819dfd004df557194f718126ecb5ca8755

3 years agohaltest: use memory pointer intead TBM_UT_INVALID_UINT_VALUE 45/252245/1
Changyeon Lee [Tue, 26 Jan 2021 04:40:53 +0000 (13:40 +0900)]
haltest: use memory pointer intead TBM_UT_INVALID_UINT_VALUE

Change-Id: I9e114a1e4c472a8db8a463d8d2868d22e4aa3a19

3 years agopackage version up to 3.3.15 60/251360/2 accepted/tizen/unified/20210115.125753 submit/tizen/20210114.082939
Changyeon Lee [Wed, 13 Jan 2021 04:50:58 +0000 (13:50 +0900)]
package version up to 3.3.15

Change-Id: I6bfac4c03367f56c020911c8c7eaa50cd02301c4

3 years agofix typo 05/250805/3
Shinwoo Kim [Tue, 5 Jan 2021 01:37:08 +0000 (10:37 +0900)]
fix typo

Change-Id: I07584c7153e4f4a4faf752ba78aef54ce7e10489
Signed-off-by: Shinwoo Kim <cinoo.kim@samsung.com>
3 years agosurface: clean up tbm_surface_internal_set_debug_data 00/251100/3
Changyeon Lee [Fri, 8 Jan 2021 04:17:46 +0000 (13:17 +0900)]
surface: clean up tbm_surface_internal_set_debug_data

Change-Id: I08b2994f273f6ac3413d4a8bcb2216bc884f0442

3 years agosurface: move function of allocating for surface to tbm_bo 99/251099/2
Changyeon Lee [Thu, 7 Jan 2021 10:36:50 +0000 (19:36 +0900)]
surface: move function of allocating for surface to tbm_bo

Change-Id: Ic71bf090a534da9cb7ffd4c086c34c268b60f67e

3 years agobo: use magic number for checking valid of bo 98/251098/1
Changyeon Lee [Thu, 7 Jan 2021 08:22:00 +0000 (17:22 +0900)]
bo: use magic number for checking valid of bo

Change-Id: I4bb5a73da0c9afc3fb6040e9063f5c1d92d87df2

3 years agosurface: use magic number for checking valid of surface 97/251097/1
Changyeon Lee [Thu, 7 Jan 2021 08:02:25 +0000 (17:02 +0900)]
surface: use magic number for checking valid of surface

Change-Id: If6c987d276c97d2a21ba38c76d0a01e66cbdcfe5

3 years agosurface_queue: use magic number for checking valid of surface_queue 57/250757/2
Changyeon Lee [Mon, 4 Jan 2021 09:13:50 +0000 (18:13 +0900)]
surface_queue: use magic number for checking valid of surface_queue

Change-Id: Ie244b00d8c03b6b56815b1506270ea99b4be76cf

4 years agopackage version up to 3.3.14 86/244786/2 accepted/tizen/unified/20210104.130317 submit/tizen/20200924.074306 submit/tizen/20201231.043706
Changyeon Lee [Thu, 24 Sep 2020 07:19:18 +0000 (16:19 +0900)]
package version up to 3.3.14

Change-Id: Id3c861e3ff2a2b7874bd56ca1f1e6a770b5d5e56

4 years agotbm_surface_queue: notify reset callback in free_flush 78/244778/4
Changyeon Lee [Thu, 24 Sep 2020 06:16:55 +0000 (15:16 +0900)]
tbm_surface_queue: notify reset callback in free_flush

ddk should know that free buffer is destroyed

Change-Id: Id9031a0cdcc167fb89ce0d9c0c53f1ef68478917

4 years agopackage version up to 3.3.13 22/239622/1 accepted/tizen_6.0_unified_hotfix tizen_6.0_hotfix accepted/tizen/6.0/unified/20201030.114332 accepted/tizen/6.0/unified/hotfix/20201103.002627 accepted/tizen/unified/20200729.165648 submit/tizen/20200728.082326 submit/tizen_6.0/20201029.205105 submit/tizen_6.0_hotfix/20201102.192505 submit/tizen_6.0_hotfix/20201103.114805 tizen_6.0.m2_release
SooChan Lim [Tue, 28 Jul 2020 07:57:55 +0000 (16:57 +0900)]
package version up to 3.3.13

Change-Id: I385d21ebb6dfa597ac0edef9693eca4839f874e2

4 years agochange the _tmpfilesdir to /usr/lib 21/239621/1
SooChan Lim [Tue, 28 Jul 2020 07:57:04 +0000 (16:57 +0900)]
change the _tmpfilesdir to /usr/lib

Change-Id: I5b7d4a2f23591a7c6c3a32cd15767fe6d8c97924

4 years agopackage version up to 3.3.12 26/237626/1 accepted/tizen/unified/20200703.014551 submit/tizen/20200702.040708 submit/tizen/20200702.040745
SooChan Lim [Thu, 2 Jul 2020 02:39:20 +0000 (11:39 +0900)]
package version up to 3.3.12

Change-Id: I980eb0eeec6077a639ec9ea9c04c2bfe87bfa5cd

4 years agobufmgr: do not print backend information on stdout 15/237615/1
SooChan Lim [Thu, 2 Jul 2020 01:33:53 +0000 (10:33 +0900)]
bufmgr: do not print backend information on stdout

Change-Id: I88d0c80e48cdcb1a2c6023eb9fc9ce10dfb90153

4 years agopackage version up to 3.3.11 33/237233/1 accepted/tizen/unified/20200630.131407 submit/tizen/20200626.065636
Junkyeong Kim [Fri, 26 Jun 2020 06:35:46 +0000 (15:35 +0900)]
package version up to 3.3.11

Change-Id: I0062a5eaede2e3f34ceda164a25a430c83e98624
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
4 years agohaltest: erase unnecessary tc 32/237232/1
Junkyeong Kim [Fri, 26 Jun 2020 06:35:02 +0000 (15:35 +0900)]
haltest: erase unnecessary tc

Change-Id: I60f5f303d0cbdebcac2fa723007551dedf213f3b
Signed-off-by: Junkyeong Kim <jk0430.kim@samsung.com>
4 years agopackage version up to 3.3.10 61/236861/3 accepted/tizen/unified/20200624.130238 submit/tizen/20200623.060802
SooChan Lim [Tue, 23 Jun 2020 02:22:19 +0000 (11:22 +0900)]
package version up to 3.3.10

Change-Id: If19ec6edd8cd85c6948cabc54ca4363e71b82957