Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F143351682
D40049.id122633.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D40049.id122633.diff
View Options
diff --git a/lib/libpmc/libpmc.c b/lib/libpmc/libpmc.c
--- a/lib/libpmc/libpmc.c
+++ b/lib/libpmc/libpmc.c
@@ -1195,6 +1195,7 @@
{
struct pmc_op_configurelog cla;
+ cla.pm_flags = 0;
cla.pm_logfd = fd;
if (PMC_CALL(CONFIGURELOG, &cla) < 0)
return (-1);
diff --git a/share/man/man4/hwpmc.4 b/share/man/man4/hwpmc.4
--- a/share/man/man4/hwpmc.4
+++ b/share/man/man4/hwpmc.4
@@ -598,6 +598,12 @@
.Dv PMC_OP_GETPMCINFO
operation.
.It Bq Er EINVAL
+The
+.Ar pm_flags
+argument to a
+.Dv PMC_OP_CONFIGURELOG
+request contained unknown flags.
+.It Bq Er EINVAL
A
.Dv PMC_OP_CONFIGURELOG
request to de-configure a log file was issued without a log file
diff --git a/sys/dev/hwpmc/hwpmc_mod.c b/sys/dev/hwpmc/hwpmc_mod.c
--- a/sys/dev/hwpmc/hwpmc_mod.c
+++ b/sys/dev/hwpmc/hwpmc_mod.c
@@ -3438,6 +3438,12 @@
break;
}
+ /* No flags currently implemented */
+ if (cl.pm_flags != 0) {
+ error = EINVAL;
+ break;
+ }
+
/* mark this process as owning a log file */
p = td->td_proc;
if ((po = pmc_find_owner_descriptor(p)) == NULL)
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Jan 30, 7:09 AM (20 h, 57 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
28096409
Default Alt Text
D40049.id122633.diff (1 KB)
Attached To
Mode
D40049: pmc: Initialise and check the pm_flags field for CONFIGURELOG
Attached
Detach File
Event Timeline
Log In to Comment