提交 903dba1e 编写于 作者: J Jean Delvare 提交者: Takashi Iwai

ALSA: keywest: Get rid of useless i2c_device_name() macro

The i2c_device_name() macro is used only once and doesn't have much
value, it hurts redability more than it helps. Get rid of it.
Signed-off-by: NJean Delvare <khali@linux-fr.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: NTakashi Iwai <tiwai@suse.de>
上级 a4d7749b
......@@ -33,10 +33,6 @@
static struct pmac_keywest *keywest_ctx;
#ifndef i2c_device_name
#define i2c_device_name(x) ((x)->name)
#endif
static int keywest_probe(struct i2c_client *client,
const struct i2c_device_id *id)
{
......@@ -56,7 +52,7 @@ static int keywest_attach_adapter(struct i2c_adapter *adapter)
if (! keywest_ctx)
return -EINVAL;
if (strncmp(i2c_device_name(adapter), "mac-io", 6))
if (strncmp(adapter->name, "mac-io", 6))
return 0; /* ignored */
memset(&info, 0, sizeof(struct i2c_board_info));
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册