Print this page
NEX-1643 dtrace provider for smbsrv
Also illumos 1841:
 DTrace smb provider was mis-implemented, doesn't exist.
Add back handlers for read/write raw, so that
 legacy dtrace consumers can find the probes.
Kill extra arg in smb_negotiate
Fix missing "done" probe with smb_notify
Add example consumer: smb-trace.d
fix soi_pid

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/fs/smbsrv/smb_negotiate.c
          +++ new/usr/src/uts/common/fs/smbsrv/smb_negotiate.c
↓ open down ↓ 374 lines elided ↑ open up ↑
 375  375                  if (dialect >= DIALECT_SMB2002 &&
 376  376                      skc->skc_max_protocol < SMB_VERS_2_BASE)
 377  377                          continue;
 378  378  
 379  379                  if (negprot->ni_dialect < dialect) {
 380  380                          negprot->ni_dialect = dialect;
 381  381                          negprot->ni_index = pos;
 382  382                  }
 383  383          }
 384  384  
 385      -        DTRACE_SMB_2(op__Negotiate__start, smb_request_t *, sr,
 386      -            smb_arg_negotiate_t, negprot);
      385 +        DTRACE_SMB_1(op__Negotiate__start, smb_request_t *, sr);
 387  386  
 388  387          return ((rc == 0) ? SDRC_SUCCESS : SDRC_ERROR);
 389  388  }
 390  389  
 391  390  void
 392  391  smb_post_negotiate(smb_request_t *sr)
 393  392  {
 394  393          smb_arg_negotiate_t     *negprot = sr->sr_negprot;
 395  394  
 396      -        DTRACE_SMB_2(op__Negotiate__done, smb_request_t *, sr,
 397      -            smb_arg_negotiate_t, negprot);
      395 +        DTRACE_SMB_1(op__Negotiate__done, smb_request_t *, sr);
 398  396  
 399  397          bzero(negprot, sizeof (smb_arg_negotiate_t));
 400  398  }
 401  399  
 402  400  smb_sdrc_t
 403  401  smb_com_negotiate(smb_request_t *sr)
 404  402  {
 405  403          smb_session_t           *session = sr->session;
 406  404          smb_arg_negotiate_t     *negprot = sr->sr_negprot;
 407  405          uint16_t                secmode;
↓ open down ↓ 241 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX