Message type for COMMON_REQ_GCOV_DATA.
Change-Id: I97d31059990e33411a685d5d8191c728a02e7d0f
This commit is contained in:
		
							parent
							
								
									d1e784760d
								
							
						
					
					
						commit
						6082b2b4de
					
				@ -577,10 +577,6 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
/* Common request to all processes: gcov data. */
 | 
					/* Common request to all processes: gcov data. */
 | 
				
			||||||
#define COMMON_REQ_GCOV_DATA (COMMON_RQ_BASE+1)
 | 
					#define COMMON_REQ_GCOV_DATA (COMMON_RQ_BASE+1)
 | 
				
			||||||
#	define GCOV_GRANT   m1_i2
 | 
					 | 
				
			||||||
#	define GCOV_PID     m1_i3
 | 
					 | 
				
			||||||
#	define GCOV_BUFF_P  m1_p1
 | 
					 | 
				
			||||||
#	define GCOV_BUFF_SZ m1_i1
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
/* Common fault injection ctl request to all processes. */
 | 
					/* Common fault injection ctl request to all processes. */
 | 
				
			||||||
#define COMMON_REQ_FI_CTL (COMMON_RQ_BASE+2)
 | 
					#define COMMON_REQ_FI_CTL (COMMON_RQ_BASE+2)
 | 
				
			||||||
 | 
				
			|||||||
@ -101,6 +101,16 @@ typedef struct {
 | 
				
			|||||||
} mess_lsys_krn_readbios;
 | 
					} mess_lsys_krn_readbios;
 | 
				
			||||||
_ASSERT_MSG_SIZE(mess_lsys_krn_readbios);
 | 
					_ASSERT_MSG_SIZE(mess_lsys_krn_readbios);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					typedef struct {
 | 
				
			||||||
 | 
						cp_grant_id_t grant;
 | 
				
			||||||
 | 
						int pid;
 | 
				
			||||||
 | 
						vir_bytes buff_p;
 | 
				
			||||||
 | 
						size_t buff_sz;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
						uint8_t padding[40];
 | 
				
			||||||
 | 
					} mess_lc_vfs_gcov;
 | 
				
			||||||
 | 
					_ASSERT_MSG_SIZE(mess_lc_vfs_gcov);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
typedef struct {
 | 
					typedef struct {
 | 
				
			||||||
	off_t pos;
 | 
						off_t pos;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -2036,6 +2046,7 @@ typedef struct {
 | 
				
			|||||||
		mess_lblockdriver_lbdev_reply m_lblockdriver_lbdev_reply;
 | 
							mess_lblockdriver_lbdev_reply m_lblockdriver_lbdev_reply;
 | 
				
			||||||
		mess_lc_pm_cprof	m_lc_pm_cprof;
 | 
							mess_lc_pm_cprof	m_lc_pm_cprof;
 | 
				
			||||||
		mess_lc_pm_sprof	m_lc_pm_sprof;
 | 
							mess_lc_pm_sprof	m_lc_pm_sprof;
 | 
				
			||||||
 | 
							mess_lc_vfs_gcov	m_lc_vfs_gcov;
 | 
				
			||||||
		mess_lsys_krn_sys_diagctl m_lsys_krn_sys_diagctl;
 | 
							mess_lsys_krn_sys_diagctl m_lsys_krn_sys_diagctl;
 | 
				
			||||||
		mess_lsys_krn_sys_cprof m_lsys_krn_sys_cprof;
 | 
							mess_lsys_krn_sys_cprof m_lsys_krn_sys_cprof;
 | 
				
			||||||
		mess_lsys_krn_sys_profbuf m_lsys_krn_sys_profbuf;
 | 
							mess_lsys_krn_sys_profbuf m_lsys_krn_sys_profbuf;
 | 
				
			||||||
 | 
				
			|||||||
@ -7,9 +7,9 @@ int gcov_flush_svr(char *buff, int buff_sz, int server_nr)
 | 
				
			|||||||
	message m;
 | 
						message m;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	memset(&m, 0, sizeof(m));
 | 
						memset(&m, 0, sizeof(m));
 | 
				
			||||||
	m.GCOV_BUFF_P = buff;
 | 
						m.m_lc_vfs_gcov.buff_p = buff;
 | 
				
			||||||
	m.GCOV_BUFF_SZ = buff_sz;
 | 
						m.m_lc_vfs_gcov.buff_sz = buff_sz;
 | 
				
			||||||
	m.GCOV_PID = server_nr;
 | 
						m.m_lc_vfs_gcov.pid = server_nr;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	/* Make the call to server. It will call the gcov library,
 | 
						/* Make the call to server. It will call the gcov library,
 | 
				
			||||||
	 * buffer the stdio requests, and copy the buffer to this user
 | 
						 * buffer the stdio requests, and copy the buffer to this user
 | 
				
			||||||
 | 
				
			|||||||
@ -154,7 +154,8 @@ int do_gcov_flush_impl(message *msg)
 | 
				
			|||||||
	assert(msg->m_type == COMMON_REQ_GCOV_DATA);
 | 
						assert(msg->m_type == COMMON_REQ_GCOV_DATA);
 | 
				
			||||||
	assert(msg->m_source == VFS_PROC_NR);
 | 
						assert(msg->m_source == VFS_PROC_NR);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	replymsg.m_type = gcov_flush(msg->GCOV_GRANT, msg->GCOV_BUFF_SZ);
 | 
						replymsg.m_type = gcov_flush(msg->m_lc_vfs_gcov.grant,
 | 
				
			||||||
 | 
							msg->m_lc_vfs_gcov.buff_sz);
 | 
				
			||||||
	return ipc_send(msg->m_source, &replymsg);
 | 
						return ipc_send(msg->m_source, &replymsg);
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -23,9 +23,9 @@ int do_gcov_flush()
 | 
				
			|||||||
  message m;
 | 
					  message m;
 | 
				
			||||||
  vir_bytes buf;
 | 
					  vir_bytes buf;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  size = job_m_in.GCOV_BUFF_SZ;
 | 
					  size = job_m_in.m_lc_vfs_gcov.buff_sz;
 | 
				
			||||||
  target = job_m_in.GCOV_PID;
 | 
					  target = job_m_in.m_lc_vfs_gcov.pid;
 | 
				
			||||||
  buf = (vir_bytes) job_m_in.GCOV_BUFF_P;
 | 
					  buf = job_m_in.m_lc_vfs_gcov.buff_p;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  /* If the wrong process is sent to, the system hangs; so make this root-only.
 | 
					  /* If the wrong process is sent to, the system hangs; so make this root-only.
 | 
				
			||||||
   */
 | 
					   */
 | 
				
			||||||
@ -55,8 +55,8 @@ int do_gcov_flush()
 | 
				
			|||||||
	r = gcov_flush(grantid, size);
 | 
						r = gcov_flush(grantid, size);
 | 
				
			||||||
  } else {
 | 
					  } else {
 | 
				
			||||||
	/* Perform generic GCOV request. */
 | 
						/* Perform generic GCOV request. */
 | 
				
			||||||
	m.GCOV_GRANT = grantid;
 | 
						m.m_lc_vfs_gcov.grant = grantid;
 | 
				
			||||||
	m.GCOV_BUFF_SZ = size;
 | 
						m.m_lc_vfs_gcov.buff_sz = size;
 | 
				
			||||||
	r = _taskcall(rfp->fp_endpoint, COMMON_REQ_GCOV_DATA, &m);
 | 
						r = _taskcall(rfp->fp_endpoint, COMMON_REQ_GCOV_DATA, &m);
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user