Displaying 20 results from an estimated 26 matches for "drm_gem_vram_of_bo".
2019 Apr 30
2
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...; +/**
> >> + * Returns the container of type &struct drm_gem_vram_object
> >> + * for field bo.
> >> + * @bo: the VRAM buffer object
> >> + * Returns: The containing GEM VRAM object
> >> + */
> >> +static inline struct drm_gem_vram_object* drm_gem_vram_of_bo(
> >> + struct ttm_buffer_object *bo)
> >> +{
> >> + return container_of(bo, struct drm_gem_vram_object, bo);
> >> +}
> > Indent funny. USe same indent as used in other parts of file for
> > function arguments.
>
> If I put the argument next to...
2019 Apr 30
2
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...; +/**
> >> + * Returns the container of type &struct drm_gem_vram_object
> >> + * for field bo.
> >> + * @bo: the VRAM buffer object
> >> + * Returns: The containing GEM VRAM object
> >> + */
> >> +static inline struct drm_gem_vram_object* drm_gem_vram_of_bo(
> >> + struct ttm_buffer_object *bo)
> >> +{
> >> + return container_of(bo, struct drm_gem_vram_object, bo);
> >> +}
> > Indent funny. USe same indent as used in other parts of file for
> > function arguments.
>
> If I put the argument next to...
2019 May 03
2
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...type &struct drm_gem_vram_object
>>>>> + * for field bo.
>>>>> + * @bo: the VRAM buffer object
>>>>> + * Returns: The containing GEM VRAM object
>>>>> + */
>>>>> +static inline struct drm_gem_vram_object* drm_gem_vram_of_bo(
>>>>> + struct ttm_buffer_object *bo)
>>>>> +{
>>>>> + return container_of(bo, struct drm_gem_vram_object, bo);
>>>>> +}
>>>> Indent funny. USe same indent as used in other parts of file for
>>>> function argumen...
2019 May 03
2
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...type &struct drm_gem_vram_object
>>>>> + * for field bo.
>>>>> + * @bo: the VRAM buffer object
>>>>> + * Returns: The containing GEM VRAM object
>>>>> + */
>>>>> +static inline struct drm_gem_vram_object* drm_gem_vram_of_bo(
>>>>> + struct ttm_buffer_object *bo)
>>>>> +{
>>>>> + return container_of(bo, struct drm_gem_vram_object, bo);
>>>>> +}
>>>> Indent funny. USe same indent as used in other parts of file for
>>>> function argumen...
2019 May 03
2
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...;>>>>>> + * for field bo.
>>>>>>> + * @bo: the VRAM buffer object
>>>>>>> + * Returns: The containing GEM VRAM object
>>>>>>> + */
>>>>>>> +static inline struct drm_gem_vram_object* drm_gem_vram_of_bo(
>>>>>>> + struct ttm_buffer_object *bo)
>>>>>>> +{
>>>>>>> + return container_of(bo, struct drm_gem_vram_object, bo);
>>>>>>> +}
>>>>>> Indent funny. USe same indent as used in other parts of fi...
2019 May 03
2
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...;>>>>>> + * for field bo.
>>>>>>> + * @bo: the VRAM buffer object
>>>>>>> + * Returns: The containing GEM VRAM object
>>>>>>> + */
>>>>>>> +static inline struct drm_gem_vram_object* drm_gem_vram_of_bo(
>>>>>>> + struct ttm_buffer_object *bo)
>>>>>>> +{
>>>>>>> + return container_of(bo, struct drm_gem_vram_object, bo);
>>>>>>> +}
>>>>>> Indent funny. USe same indent as used in other parts of fi...
2019 Apr 24
0
[PATCH v2 02/17] drm: Add |struct drm_gem_vram_object| callbacks for |struct ttm_bo_driver|
...vram_object.bo
+ * @pl: TTM placement information.
+ */
+void drm_gem_vram_bo_driver_evict_flags(struct ttm_buffer_object *bo,
+ struct ttm_placement *pl)
+{
+ struct drm_gem_vram_object *gbo;
+
+ /* TTM may pass BOs that are not GEM VRAM BOs. */
+ if (!drm_is_gem_vram(bo))
+ return;
+
+ gbo = drm_gem_vram_of_bo(bo);
+ drm_gem_vram_placement(gbo, TTM_PL_FLAG_SYSTEM);
+ *pl = gbo->placement;
+}
+EXPORT_SYMBOL(drm_gem_vram_bo_driver_evict_flags);
+
+/**
+ * drm_gem_vram_bo_driver_verify_access() - \
+ Implements &struct ttm_bo_driver.verify_access
+ * @bo: TTM buffer object. Refers to &struct drm...
2019 Apr 29
0
[PATCH v3 02/19] drm: Add |struct drm_gem_vram_object| callbacks for |struct ttm_bo_driver|
...vram_object.bo
+ * @pl: TTM placement information.
+ */
+void drm_gem_vram_bo_driver_evict_flags(struct ttm_buffer_object *bo,
+ struct ttm_placement *pl)
+{
+ struct drm_gem_vram_object *gbo;
+
+ /* TTM may pass BOs that are not GEM VRAM BOs. */
+ if (!drm_is_gem_vram(bo))
+ return;
+
+ gbo = drm_gem_vram_of_bo(bo);
+ drm_gem_vram_placement(gbo, TTM_PL_FLAG_SYSTEM);
+ *pl = gbo->placement;
+}
+EXPORT_SYMBOL(drm_gem_vram_bo_driver_evict_flags);
+
+/**
+ * drm_gem_vram_bo_driver_verify_access() - \
+ Implements &struct ttm_bo_driver.verify_access
+ * @bo: TTM buffer object. Refers to &struct drm...
2019 Apr 30
0
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...ns the container of type &struct drm_gem_vram_object
>>>> + * for field bo.
>>>> + * @bo: the VRAM buffer object
>>>> + * Returns: The containing GEM VRAM object
>>>> + */
>>>> +static inline struct drm_gem_vram_object* drm_gem_vram_of_bo(
>>>> + struct ttm_buffer_object *bo)
>>>> +{
>>>> + return container_of(bo, struct drm_gem_vram_object, bo);
>>>> +}
>>> Indent funny. USe same indent as used in other parts of file for
>>> function arguments.
>> If I put th...
2019 May 06
0
[PATCH v4 02/19] drm: Add |struct drm_gem_vram_object| callbacks for |struct ttm_bo_driver|
...vram_object.bo
+ * @pl: TTM placement information.
+ */
+void drm_gem_vram_bo_driver_evict_flags(struct ttm_buffer_object *bo,
+ struct ttm_placement *pl)
+{
+ struct drm_gem_vram_object *gbo;
+
+ /* TTM may pass BOs that are not GEM VRAM BOs. */
+ if (!drm_is_gem_vram(bo))
+ return;
+
+ gbo = drm_gem_vram_of_bo(bo);
+ drm_gem_vram_placement(gbo, TTM_PL_FLAG_SYSTEM);
+ *pl = gbo->placement;
+}
+EXPORT_SYMBOL(drm_gem_vram_bo_driver_evict_flags);
+
+/**
+ * drm_gem_vram_bo_driver_verify_access() - \
+ Implements &struct ttm_bo_driver.verify_access
+ * @bo: TTM buffer object. Refers to &struct drm...
2019 May 03
0
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...vram_object
> >>>>> + * for field bo.
> >>>>> + * @bo: the VRAM buffer object
> >>>>> + * Returns: The containing GEM VRAM object
> >>>>> + */
> >>>>> +static inline struct drm_gem_vram_object* drm_gem_vram_of_bo(
> >>>>> + struct ttm_buffer_object *bo)
> >>>>> +{
> >>>>> + return container_of(bo, struct drm_gem_vram_object, bo);
> >>>>> +}
> >>>> Indent funny. USe same indent as used in other parts of file for
> >...
2019 Apr 24
1
[PATCH v2 02/17] drm: Add |struct drm_gem_vram_object| callbacks for |struct ttm_bo_driver|
...+ */
> +void drm_gem_vram_bo_driver_evict_flags(struct ttm_buffer_object *bo,
> + struct ttm_placement *pl)
> +{
> + struct drm_gem_vram_object *gbo;
> +
> + /* TTM may pass BOs that are not GEM VRAM BOs. */
> + if (!drm_is_gem_vram(bo))
> + return;
> +
> + gbo = drm_gem_vram_of_bo(bo);
> + drm_gem_vram_placement(gbo, TTM_PL_FLAG_SYSTEM);
> + *pl = gbo->placement;
> +}
For drm_is_gem_vram(), I'm not quite sure what else to test for. So
there are still a few things I'd like to discuss.
1) If this test is about the placement flags, then it's unrelated...
2019 May 03
0
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...;>> + * for field bo.
>>>>>>>> + * @bo: the VRAM buffer object
>>>>>>>> + * Returns: The containing GEM VRAM object
>>>>>>>> + */
>>>>>>>> +static inline struct drm_gem_vram_object* drm_gem_vram_of_bo(
>>>>>>>> + struct ttm_buffer_object *bo)
>>>>>>>> +{
>>>>>>>> + return container_of(bo, struct drm_gem_vram_object, bo);
>>>>>>>> +}
>>>>>>> Indent funny. USe same indent as used...
2019 Apr 29
4
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...gbo->gem);
> +}
> +
> +static void drm_gem_vram_destroy(struct drm_gem_vram_object *gbo)
> +{
> + drm_gem_vram_cleanup(gbo);
> + kfree(gbo);
> +}
> +
> +static void ttm_buffer_object_destroy(struct ttm_buffer_object *bo)
> +{
> + struct drm_gem_vram_object *gbo = drm_gem_vram_of_bo(bo);
> + drm_gem_vram_destroy(gbo);
> +}
> +
> +static void drm_gem_vram_placement(struct drm_gem_vram_object *gbo, int pl_flag)
> +{
> + unsigned int i;
> + unsigned int c = 0;
> +
> + gbo->placement.placement = gbo->placements;
> + gbo->placement.busy_placem...
2019 Apr 29
4
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...gbo->gem);
> +}
> +
> +static void drm_gem_vram_destroy(struct drm_gem_vram_object *gbo)
> +{
> + drm_gem_vram_cleanup(gbo);
> + kfree(gbo);
> +}
> +
> +static void ttm_buffer_object_destroy(struct ttm_buffer_object *bo)
> +{
> + struct drm_gem_vram_object *gbo = drm_gem_vram_of_bo(bo);
> + drm_gem_vram_destroy(gbo);
> +}
> +
> +static void drm_gem_vram_placement(struct drm_gem_vram_object *gbo, int pl_flag)
> +{
> + unsigned int i;
> + unsigned int c = 0;
> +
> + gbo->placement.placement = gbo->placements;
> + gbo->placement.busy_placem...
2019 Sep 09
5
[PATCH 0/4] Merge VRAM MM and GEM VRAM source files
VRAM MM and GEM VRAM are only used with each other. This patch set
moves VRAM MM into GEM VRAM source files and cleans up the helper's
public interface.
Thomas Zimmermann (4):
drm/vram: Move VRAM memory manager to GEM VRAM implementation
drm/vram: Have VRAM MM call GEM VRAM functions directly
drm/vram: Unexport internal functions of VRAM MM
drm/vram: Unconditonally set BO call-back
2019 Sep 11
4
[PATCH v2 0/4] Merge VRAM MM and GEM VRAM source files
VRAM MM and GEM VRAM are only used with each other. This patch set
moves VRAM MM into GEM VRAM source files and cleans up the helper's
public interface.
Version 2 of the patch set doesn't contain functional changes. I'm
reposting due to the rebasing onto the debugfs patches.
v2:
* updated for debugfs support
* fixed typos in comments
Thomas Zimmermann (4):
drm/vram: Move VRAM
2019 May 06
0
[PATCH v4 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...se the GEM object.
+ */
+ drm_gem_object_release(&gbo->gem);
+}
+
+static void drm_gem_vram_destroy(struct drm_gem_vram_object *gbo)
+{
+ drm_gem_vram_cleanup(gbo);
+ kfree(gbo);
+}
+
+static void ttm_buffer_object_destroy(struct ttm_buffer_object *bo)
+{
+ struct drm_gem_vram_object *gbo = drm_gem_vram_of_bo(bo);
+
+ drm_gem_vram_destroy(gbo);
+}
+
+static void drm_gem_vram_placement(struct drm_gem_vram_object *gbo,
+ unsigned long pl_flag)
+{
+ unsigned int i;
+ unsigned int c = 0;
+
+ gbo->placement.placement = gbo->placements;
+ gbo->placement.busy_placement = gbo->placements;
+
+...
2019 Apr 29
0
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...lease the GEM object. */
+ drm_gem_object_release(&gbo->gem);
+}
+
+static void drm_gem_vram_destroy(struct drm_gem_vram_object *gbo)
+{
+ drm_gem_vram_cleanup(gbo);
+ kfree(gbo);
+}
+
+static void ttm_buffer_object_destroy(struct ttm_buffer_object *bo)
+{
+ struct drm_gem_vram_object *gbo = drm_gem_vram_of_bo(bo);
+ drm_gem_vram_destroy(gbo);
+}
+
+static void drm_gem_vram_placement(struct drm_gem_vram_object *gbo, int pl_flag)
+{
+ unsigned int i;
+ unsigned int c = 0;
+
+ gbo->placement.placement = gbo->placements;
+ gbo->placement.busy_placement = gbo->placements;
+
+ if (pl_flag & TT...
2019 Apr 30
0
[PATCH v3 01/19] drm: Add |struct drm_gem_vram_object| and helpers
...reporting.
>> +
>> +/**
>> + * Returns the container of type &struct drm_gem_vram_object
>> + * for field bo.
>> + * @bo: the VRAM buffer object
>> + * Returns: The containing GEM VRAM object
>> + */
>> +static inline struct drm_gem_vram_object* drm_gem_vram_of_bo(
>> + struct ttm_buffer_object *bo)
>> +{
>> + return container_of(bo, struct drm_gem_vram_object, bo);
>> +}
> Indent funny. USe same indent as used in other parts of file for
> function arguments.
If I put the argument next to the function's name, it will exceed...