Don't pin buffers using TEGRA_DC_EXT_SET_PROPOSED_BW. The buffers don't
need to be accessed at all, they only need to be checked if they are
NULL or not. Setting a fake buffer for this call will now be valid, so
simply pass 1 or 0 for the buff_id to indicate which windows are enabled
or disabled.
Change-Id: I940c1ec4a708bfc38c7b5606782859017e51a0d2
Signed-off-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-on: http://git-master/r/383952
(cherry picked from commit
a056f50049b89901bd3c0bb2335977002fc980eb)
Signed-off-by: Robert Shih <rshih@nvidia.com>
Reviewed-on: http://git-master/r/386570
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Thomas Cherry <tcherry@nvidia.com>
int ret;
struct tegra_dc_win *dc_wins[DC_N_WINDOWS];
struct tegra_dc *dc = user->ext->dc;
- struct tegra_dc_dmabuf *handle;
- dma_addr_t phys_addr;
/* If display has been disconnected return with error. */
if (!dc->connected)
for (i = 0; i < win_num; i++) {
int idx = wins[i].index;
- ret = tegra_dc_ext_pin_window(user, wins[i].buff_id,
- &handle, &phys_addr);
- if (ret)
- return ret;
-
- if (handle) {
- dma_buf_unmap_attachment(handle->attach,
- handle->sgt, DMA_TO_DEVICE);
- dma_buf_put(handle->buf);
- kfree(handle);
+ if (wins[i].buff_id > 0) {
tegra_dc_ext_set_windowattr_basic(&dc->tmp_wins[idx],
&wins[i]);
}