From: "james qian wang (Arm Technology China)" <james.qian.wang@arm.com>
To: Dan Carpenter <dan.carpenter@oracle.com>
Cc: nd <nd@arm.com>,
"dri-devel@lists.freedesktop.org"
<dri-devel@lists.freedesktop.org>
Subject: Re: [bug report] drm/komeda: Add writeback support
Date: Mon, 19 Aug 2019 07:11:44 +0000 [thread overview]
Message-ID: <20190819071137.GA6502@jamwan02-TSP300> (raw)
In-Reply-To: <20190814140930.GA31850@mwanda>
On Wed, Aug 14, 2019 at 05:09:30PM +0300, Dan Carpenter wrote:
> Hello james qian wang (Arm Technology China),
>
> The patch 5d51f6c0da1b: "drm/komeda: Add writeback support" from May
> 23, 2019, leads to the following static checker warning:
>
> drivers/gpu/drm/arm/display/komeda/komeda_wb_connector.c:151 komeda_wb_connector_add()
> error: not allocating enough data 1592 vs 1584
>
> drivers/gpu/drm/arm/display/komeda/komeda_wb_connector.c
> 139 static int komeda_wb_connector_add(struct komeda_kms_dev *kms,
> 140 struct komeda_crtc *kcrtc)
> 141 {
> 142 struct komeda_dev *mdev = kms->base.dev_private;
> 143 struct komeda_wb_connector *kwb_conn;
> 144 struct drm_writeback_connector *wb_conn;
> 145 u32 *formats, n_formats = 0;
> 146 int err;
> 147
> 148 if (!kcrtc->master->wb_layer)
> 149 return 0;
> 150
> 151 kwb_conn = kzalloc(sizeof(*wb_conn), GFP_KERNEL);
> ^^^^^^^
> This should probably be "kwb_conn" with a k?
Hi Dan:
Thank you very much, I'll correct it ASAP.
BTW:
Seems this error had been detected by a static parser, if possible
can you share your tools or your command for how to catch such problem
thanks
James.
> 152 if (!kwb_conn)
> 153 return -ENOMEM;
> 154
> 155 kwb_conn->wb_layer = kcrtc->master->wb_layer;
> 156
> 157 wb_conn = &kwb_conn->base;
> 158 wb_conn->encoder.possible_crtcs = BIT(drm_crtc_index(&kcrtc->base));
> 159
> 160 formats = komeda_get_layer_fourcc_list(&mdev->fmt_tbl,
> 161 kwb_conn->wb_layer->layer_type,
> 162 &n_formats);
>
> regards,
> dan carpenter
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
prev parent reply other threads:[~2019-08-19 7:11 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-14 14:09 [bug report] drm/komeda: Add writeback support Dan Carpenter
2019-08-19 7:11 ` james qian wang (Arm Technology China) [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190819071137.GA6502@jamwan02-TSP300 \
--to=james.qian.wang@arm.com \
--cc=dan.carpenter@oracle.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=nd@arm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox