It seems commit
3e9a59a184ca("Add dynamic switch of ras events support.")
inadvertedly introduced the change to ignore -d option.
Fix this so that -d will disable all trace events at once like before.
Signed-off-by: Tomohiro Misono <misono.tomohiro@fujitsu.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
int fd, rc;
char fname[MAX_PATH + 1];
- enable = is_disabled_event(group, event) ? 0 : 1;
+ if (enable)
+ enable = is_disabled_event(group, event) ? 0 : 1;
snprintf(fname, sizeof(fname), "%s%s:%s\n",
enable ? "" : "!",